We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 892e9c1 commit 848e6d4Copy full SHA for 848e6d4
src/lib/atproto/rkey.ts
@@ -23,11 +23,10 @@ export function filepathToRkey(filepath: string) {
23
// regex excludes : and _ because we use those as control characters
24
// regex excludes ~ because using it gives us internal server error
25
.replace(/[^A-Za-z0-9.\-]/g, $$ => {
26
- if ($$ == '\\' || $$ == '/') {
+ if ($$ === '\\' || $$ === '/') {
27
return ':';
28
- } else {
29
- return `_${$$.charCodeAt(0).toString(36)}_`;
30
}
+ return `_${$$.charCodeAt(0).toString(36)}_`;
31
});
32
33
filepath = filepath.toLowerCase();
0 commit comments