base64decodeUnpadded function
decodes base64
Dart's native base64.decode
requires a padded base64 input String.
This function allows unpadded base64 too.
Implementation
Uint8List base64decodeUnpadded(String s) {
final needEquals = (4 - (s.length % 4)) % 4;
return base64.decode(s + ('=' * needEquals));
}