9 lines
195 B
JavaScript
9 lines
195 B
JavaScript
/**
|
|
* Trims the File protocol off the input string
|
|
* @param {string} str
|
|
* @returns {string}
|
|
*/
|
|
function trimFileProtocol(str) {
|
|
return str.startsWith("file://") ? str.slice(7) : str;
|
|
}
|
|
|