Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if (stringOrNumber && typeof stringOrNumber === 'string') {
cleanNumber = parseInt(stringOrNumber, 10);
/* Remove invalid parseInt results */
if (isNaN(cleanNumber) || !isFinite(cleanNumber)) {
cleanNumber = 0;
}
} else {
cleanNumber = stringOrNumber;
}
return cleanNumber;
}
export default EmberTetherComponent.extend({
passedPropertiesObject: null,
didReceiveAttrs() {
this._super(...arguments);
const passedPropertiesObject = this.get('passedPropertiesObject');
if (passedPropertiesObject) {
this.setProperties(passedPropertiesObject);
}
},
/* Options */
delay: 0,