'use strict'; var url = require('url'); var prependHttp = require('prepend-http'); module.exports = function (x) { var withProtocol = prependHttp(x); var parsed = url.parse(withProtocol); if (withProtocol !== x) { parsed.protocol = null; } return parsed; };
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
index.js | File | 268 B | 0644 |
|
license | File | 1.09 KB | 0644 |
|
package.json | File | 1.65 KB | 0644 |
|
readme.md | File | 1.57 KB | 0644 |
|