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

Bugfix/two factor notification #4518

Merged
merged 2 commits into from
May 16, 2022
Merged

Conversation

camilasan
Copy link
Member

Before:
bug

After:
two-factor-auth

@nimishavijay We are always using 'Mark as Read' in all notifications. May I suggest to simply always use what comes with the notification, like in this case it should be 'Cancel'. That was one of the reasons that we had this bug.

@camilasan camilasan marked this pull request as ready for review May 11, 2022 21:17
Copy link
Collaborator

@mgallien mgallien left a comment

Choose a reason for hiding this comment

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

some small comments

src/gui/tray/notificationhandler.cpp Outdated Show resolved Hide resolved
src/gui/tray/notificationhandler.cpp Outdated Show resolved Hide resolved
@claucambra
Copy link
Collaborator

The activitylistmodel test is failing, probably needs some small changes

Copy link
Member

@nimishavijay nimishavijay left a comment

Choose a reason for hiding this comment

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

Good catch!
You are right, we should not use "Mark as read" for everything and "Approve" and "Cancel" work here :)

Is this wording provided by the API itself or it is something we have to explicitly decide every time?

@camilasan
Copy link
Member Author

Is this wording provided by the API itself or it is something we have to explicitly decide every time?

It is provided by the api.

@camilasan
Copy link
Member Author

we should not use "Mark as read" for everything and "Approve" and "Cancel" work here :)

that is the thing: we shouldn't be checking for these texts. We should just display what is in the notification.

I will remove the 'Mark as Read' and just use what comes with the API.

However if nothing is provided we will use 'Dismiss', is that ok @nimishavijay?

@nimishavijay
Copy link
Member

Sounds good! 🚀

@camilasan camilasan force-pushed the bugfix/two-factor-notification branch from 5dce8a0 to a0f94ed Compare May 12, 2022 10:25
@camilasan
Copy link
Member Author

The activitylistmodel test is failing, probably needs some small changes

Yes, I am trying to understand why it is failing which is making me afraid that I might be breaking something else while fixing this issue...

@camilasan camilasan force-pushed the bugfix/two-factor-notification branch from 779be91 to 4e5bbca Compare May 13, 2022 15:33
@jancborchardt
Copy link
Member

Btw @camilasan, every notification with actions also needs a clear primary action button. In this case that would be "Approve". :)

@mgallien
Copy link
Collaborator

Btw @camilasan, every notification with actions also needs a clear primary action button. In this case that would be "Approve". :)

going to merge it as is and create a follow up issue as we need this to fix the bug that prevent people from using 2FA with Nextcloud notifications

thanks for the feedback 😄

@mgallien
Copy link
Collaborator

/backport to stable-3.5

@mgallien mgallien force-pushed the bugfix/two-factor-notification branch from 4e5bbca to 290851c Compare May 16, 2022 20:03
@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

28.6% 28.6% Coverage
0.0% 0.0% Duplication

@mgallien mgallien merged commit 6bd99f5 into master May 16, 2022
@mgallien mgallien deleted the bugfix/two-factor-notification branch May 16, 2022 20:48
@nextcloud-desktop-bot
Copy link

AppImage file: Nextcloud-PR-4518-290851c33a996fd4a9d89c60b9f5be5ae0af627e-x86_64.AppImage

To test this change/fix you can simply download above AppImage file and test it.

Please make sure to quit your existing Nextcloud app and backup your data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants