fix(login): Fix JS error on login grant page#41117
fix(login): Fix JS error on login grant page#41117susnux merged 1 commit intonextcloud:masterfrom callmemagnus:bugfix/grant__js-error
Conversation
|
/backport to stable27 |
|
/backport to stable26 |
|
That code has been in-place since NC20 via #17683. Why hasn't this lead to more bug reports... Or has it? 🤔 |
|
/backport to stable25 |
| return | ||
| } | ||
| wrapper.getElementsByClassName('icon-confirm-white').forEach(function(el) { | ||
| Array.from(wrapper.getElementsByClassName('icon-confirm-white')).forEach(function(el) { |
There was a problem hiding this comment.
Or wrapper.querySelectorAll which returns a NodeList.
There was a problem hiding this comment.
I think this is fine as querySelectorAll will have to do extra checks (the query could be anything) it will take much longer than you gain by omitting the array conversion.
There was a problem hiding this comment.
(At least when I last benchmarked both with ~1k elements it took twice as long 😅 )
Closes #41098 Signed-off-by: Magnus Anderssen <magnus@magooweb.com>
|
Cypress is unrelated this seems to happen only on foreign repositories, somehow the 3rdparty submodule does not match up and then CI fails |
|
Thanks for your first pull request and welcome to the community! Feel free to keep them coming! If you are looking for issues to tackle then have a look at this selection: https://github.com/nextcloud/server/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22 |
|
/backport to stable26 |
|
/backport to stable25 |
Summary
HTMLCollectiondoes not have aforEachmethod, so convert to array first.Checklist