Closed Kunniii closed 1 year ago
For some devices that failed when executing atob()
, even though they can launch the extension, they can only do grade_group()
. When trying grade_indie()
there is no output, the error from the console shows something like it's a problem with Arrays when retrieving student info from API.
The problem is that the Base64 in JWT token is being compressed, which means there is no padding on the encoded string. That will cause error when trying to decode it using atob()
.
Grading individuals require an email to check the group that the user is in. So, when atob()
failed, there is no email to check, causing the function fails.
Resolve that by adding a function named addPaddingToBase64()
and use it to add padding before converting it to a string.
Need more info...