summaryrefslogtreecommitdiff
path: root/std/encoding/base64url.ts
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2020-07-14 15:24:17 -0400
committerGitHub <noreply@github.com>2020-07-14 15:24:17 -0400
commitcde4dbb35132848ffece59ef9cfaccff32347124 (patch)
treecc7830968c6decde704c8cfb83c9185193dc698f /std/encoding/base64url.ts
parent9eca71caa1674c31f9cc5d4e86c03f10b59e0a00 (diff)
Use dprint for internal formatting (#6682)
Diffstat (limited to 'std/encoding/base64url.ts')
-rw-r--r--std/encoding/base64url.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/std/encoding/base64url.ts b/std/encoding/base64url.ts
index 726ea2eb8..b20878554 100644
--- a/std/encoding/base64url.ts
+++ b/std/encoding/base64url.ts
@@ -12,8 +12,9 @@ import {
export function addPaddingToBase64url(base64url: string): string {
if (base64url.length % 4 === 2) return base64url + "==";
if (base64url.length % 4 === 3) return base64url + "=";
- if (base64url.length % 4 === 1)
+ if (base64url.length % 4 === 1) {
throw new TypeError("Illegal base64url string!");
+ }
return base64url;
}