Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(NcAppSettingsDialog): unregisterSection should remove the section instead of remove all other #4798

Merged
merged 2 commits into from Nov 16, 2023

Conversation

susnux
Copy link
Contributor

@susnux susnux commented Nov 10, 2023

☑️ Resolves

There was a logic error where unregister removed all but the unregistered section.
Also fix some minor issues and only warn on duplicated name instead of error.

🏁 Checklist

  • ⛑️ Tests are included or are not applicable
  • 📘 Component documentation has been extended, updated or is not applicable

@susnux susnux added bug Something isn't working 3. to review Waiting for reviews feature: settings Related to the settings component labels Nov 10, 2023
@nickvergessen
Copy link
Contributor

I guess this fixes nextcloud/spreed#10858 ?

@nickvergessen
Copy link
Contributor

and only warn on duplicated name instead of error.

Not sure about this. Duplicate IDs are a HTML validation error and no one reads warnings :(

ShGKme
ShGKme previously requested changes Nov 10, 2023
Copy link
Contributor

@ShGKme ShGKme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

selectedSection and sorting don't work on dynamic sections rendering

@ShGKme
Copy link
Contributor

ShGKme commented Nov 10, 2023

I guess this fixes nextcloud/spreed#10858 ?

This error is caused by a typo in a provide. "Register" is provided as unregister.

	provide() {
		return {
			registerSection: this.registerSection,
			unregisterSection: this.registerSection,
		}
	},

@susnux
Copy link
Contributor Author

susnux commented Nov 11, 2023

I guess this fixes nextcloud/spreed#10858 ?

This error is caused by a typo in a provide. "Register" is provided as unregister.

Yes that is part of this fixes :)

@susnux
Copy link
Contributor Author

susnux commented Nov 11, 2023

Not sure about this. Duplicate IDs are a HTML validation error and no one reads warnings :(

@nickvergessen duplicated IDs still throw an error, only the duplicated name is a warning now.

@susnux susnux requested a review from ShGKme November 11, 2023 13:17
@susnux susnux dismissed ShGKme’s stale review November 11, 2023 13:18

Fixed all of the comments

@susnux susnux added this to the 8.0.2 milestone Nov 11, 2023
Copy link
Contributor

@ShGKme ShGKme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fine by issue solving.

But I'm not a fun of testing implementation in unit tests, because it doesn't help to check the unit and prevent further refactoring without rewriting the unit test. I can add an alternative test if it is ok for you.

susnux and others added 2 commits November 16, 2023 02:58
…on instead of remove all other

Also fix some minor issues and only warn on duplicated name instead of error

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
…ntation

Co-authored-by: Grigorii K. Shartsev <me@shgk.me>
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
@Pytal Pytal added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Nov 16, 2023
@Pytal Pytal merged commit 1505afc into master Nov 16, 2023
15 checks passed
@Pytal Pytal deleted the fix/app-settings-dialog branch November 16, 2023 19:10
@susnux susnux mentioned this pull request Nov 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish bug Something isn't working feature: settings Related to the settings component
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants