knowledgebase_law/node_modules/property-information/lib/util/case-sensitive-transform.js

12 lines
300 B
JavaScript
Raw Normal View History

2025-04-11 23:47:09 +08:00
/**
* @param {Record<string, string>} attributes
* Attributes.
* @param {string} attribute
* Attribute.
* @returns {string}
* Transformed attribute.
*/
export function caseSensitiveTransform(attributes, attribute) {
return attribute in attributes ? attributes[attribute] : attribute
}