Libraryless. Click here for Pure Java version (2505L/16K).
sS dropUriPrefix(S prefix, S uri) { prefix = dropTrailingSlash(prefix); if (empty(prefix)) ret uri; if (eq(uri, prefix) || startsWith(uri, prefix + "/")) ret substring(uri, l(prefix)); ret uri; }
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1029778 |
Snippet name: | dropUriPrefix |
Eternal ID of this version: | #1029778/1 |
Text MD5: | fc9609ddeda883697e8499dccbd9db6f |
Transpilation MD5: | 809e10ac72bedf4c7ad11292c8af9e77 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-09-14 12:33:42 |
Source code size: | 213 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 170 / 228 |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |