ab568f6b94
If the first value passed to the helper is an empty string or undefined then return the second value
11 lines
236 B
JavaScript
11 lines
236 B
JavaScript
import { helper } from '@ember/component/helper';
|
|
|
|
export function _default(params, hash) {
|
|
if (params[0] === '' || typeof params[0] === 'undefined') {
|
|
return params[1];
|
|
}
|
|
return params[0];
|
|
}
|
|
|
|
export default helper(_default);
|