0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-24 23:48:13 -05:00

Replaces non ascii characters to dashes so that it's consistent with … (#260)

refs #7313

- theme name normalisation
- detect duplicates to show a popup to override a theme
This commit is contained in:
Ryan McCarvill 2016-09-15 05:23:04 +12:00 committed by Katharina Irrgang
parent 1933f67620
commit a93ea7ee92

View file

@ -47,7 +47,8 @@ export default ModalComponent.extend({
actions: {
validateTheme(file) {
let themeName = file.name.replace(/\.zip$/, '');
let themeName = file.name.replace(/\.zip$/, '').replace(/[^\w@.]/gi, '-');
let availableThemeNames = this.get('availableThemeNames');
this.set('file', file);