Libraryless. Click here for Pure Java version (1847L/12K).
sS fixAGILink(S s) { if (!isAbsoluteURL(s)) ret s; S host = hostNameFromURL(s); if (!isAGIBlueDomain(host)) ret s; S sub = dropSuffixIC(theAGIBlueDomain(), host); if (l(sub) <= maximumDomainPartLength()) ret s; ret "http://" + theAGIBlueDomain() + hquery(mapPlus(paramsFromURL(s), domain := host)); }
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1023594 |
Snippet name: | fixAGILink (if domain is too long) |
Eternal ID of this version: | #1023594/2 |
Text MD5: | 018ff503218f60f13b14bde07966751f |
Transpilation MD5: | 55ea6accbe0c8641f0af5c7a70fa7091 |
Author: | stefan |
Category: | javax / a.i. |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-06-29 17:10:39 |
Source code size: | 319 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 264 / 379 |
Version history: | 1 change(s) |
Referenced in: | [show references] |