mirror of
https://github.com/jdalrymple/gitbeaker.git
synced 2026-01-25 16:04:01 +00:00
11 lines
213 B
JavaScript
11 lines
213 B
JavaScript
function parse(value) {
|
|
if (typeof value === 'number') return value;
|
|
else if (value.toString().includes('/')) return encodeURIComponent(value);
|
|
|
|
return parseInt(value, 10);
|
|
}
|
|
|
|
module.exports = {
|
|
parse,
|
|
};
|