Skip to content

Commit 45d4795

Browse files
committed
undo changes to generating slugs in project and user model
1 parent 6b555d8 commit 45d4795

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

server/models/collection.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ collectionSchema.set('toJSON', {
4848
});
4949

5050
collectionSchema.pre('save', function generateSlug(next) {
51-
this.slug = slugify(this.name, { lower: true, strict: true });
51+
this.slug = slugify(this.name, '_');
5252
next();
5353
});
5454

server/models/project.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ projectSchema.set('toJSON', {
5353

5454
projectSchema.pre('save', function generateSlug(next) {
5555
if (!this.slug) {
56-
this.slug = slugify(this.name, { lower: true, strict: true });
56+
this.slug = slugify(this.name, '_');
5757
}
5858
next();
5959
});

0 commit comments

Comments
 (0)