filmout_manager/dist/env/index.js

17 lines
754 B
JavaScript
Raw Normal View History

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.envInt = exports.envFloat = exports.envString = void 0;
function envString(variable, defaultString) {
return typeof process.env[variable] !== 'undefined' ? process.env[variable] : defaultString;
}
exports.envString = envString;
function envFloat(variable, defaultFloat) {
return typeof process.env[variable] !== 'undefined' ? parseFloat(process.env[variable]) : defaultFloat;
}
exports.envFloat = envFloat;
function envInt(variable, defaultInt) {
return typeof process.env[variable] !== 'undefined' ? parseInt(process.env[variable]) : defaultInt;
}
exports.envInt = envInt;
module.exports = { envString, envFloat, envInt };
//# sourceMappingURL=index.js.map