(s)
| 38446 | } |
| 38447 | return !0 |
| 38448 | } |
| 38449 | function escapePathComponent(s) { |
| 38450 | return -1 === s.indexOf('/') && -1 === s.indexOf('~') |
| 38451 | ? s |
| 38452 | : s.replace(/~/g, '~0').replace(/\//g, '~1') |
| 38453 | } |
| 38454 | function unescapePathComponent(s) { |
| 38455 | return s.replace(/~1/g, '/').replace(/~0/g, '~') |