forked from go-gitea/gitea
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Uncaught DOMException: Failed to execute 'atob' on 'Window'
There is a missing import within the `uint8-to-base64` javascript package which assumes that `atob` and `btoa` are present and exported instead of using the `window.atob` and `window.btoa` functions. This previously worked but as far as I can see things have become more strict and this no longer works. The dependency is small and I do not believe that we gain much from having this code as an external dependency. I think instead we should just consume this dependency and bring the code directly into Gitea itself - the code is itself just some standard incantation for creating base64 arrays in javascript. Therefore this PR simply removes the dependency on `uint8-to-base64` and rewrites the functions used in it. Fix go-gitea#22507 Signed-off-by: Andrew Thornton <art27@cantab.net>
- Loading branch information
Showing
3 changed files
with
18 additions
and
19 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters