discourse/app/assets/javascripts/ember-addons/utils/extract-value.js.es6

5 lines
138 B
JavaScript

export default function extractValue(desc) {
return desc.value ||
(typeof desc.initializer === 'function' && desc.initializer());
}