Skip to content

[stable17] Use @nextcloud/axios to keep the CSRF token in sync - #17455

Merged
rullzer merged 1 commit into
stable17from
fix/stable17-axios-package
Oct 15, 2019
Merged

[stable17] Use @nextcloud/axios to keep the CSRF token in sync#17455
rullzer merged 1 commit into
stable17from
fix/stable17-axios-package

Conversation

@ChristophWurst

@ChristophWurstChristophWurst commented Oct 8, 2019

Copy link
Copy Markdown
Member

Second of two partial backports of #17319

With this package update our Axios abstraction is able to listen to the CSRF token update event and adjust the Axios default accordingly. Otherwise it would use the initial CSRF token forever.


Testing is simple: go to the apps page, run _nc_event_bus.emit('csrf-token-update', {token: 123}) and try to enable/disable an app. The request will fail. This verifies that the event is properly handled by the updated lib.

@rullzerrullzer changed the title Use @nextcloud/axios to keep the CSRF token in sync[stable17] Use @nextcloud/axios to keep the CSRF token in syncOct 8, 2019
@rullzer
rullzerforce-pushed the fix/stable17-axios-package branch from fe26f46 to ea79bcaCompareOctober 14, 2019 21:30
@rullzer

Copy link
Copy Markdown
Member

/compile amend /

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Signed-off-by: npmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>
@npmbuildbot-nextcloud
npmbuildbot-nextcloudBotforce-pushed the fix/stable17-axios-package branch from ea79bca to 37cca6fCompareOctober 15, 2019 07:19
@rullzer
rullzer merged commit a5e3f69 into stable17Oct 15, 2019
@rullzer
rullzer deleted the fix/stable17-axios-package branch October 15, 2019 12:30
@rullzerrullzer mentioned this pull request Oct 28, 2019
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to reviewWaiting for reviewsbugregression

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@ChristophWurst@rullzer@skjnldsv