const config = require("config"); let basePath = config.get("basePath"); basePath = "/" + basePath.replace(/^\/+/, "").replace(/\/+$/, "") + "/"; if (basePath == "//") { basePath = "/"; } module.exports = basePath;