You can simplify the two lines above with
```javascript
if (this.name.endsWith('.' + guessedExt))
```