"use strict"; const mapObject = require("map-obj"); const matchValue = require("match-value"); const mapping = require("./mapping"); let normalizedMapping = mapObject(mapping, (key, value) => { return [ key.toLowerCase(), value ]; }); module.exports = function mapManufacturer(manufacturer) { return (manufacturer != null) ? matchValue(manufacturer.toLowerCase(), { ... normalizedMapping, _: manufacturer }) : null; };