Skip to content

Commit 4b8b0a9

Browse files
committed
add versionNumber to 5.x
1 parent 1bc07ec commit 4b8b0a9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/search.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ const contentSchema = new mongoose.Schema({
2323
title: { type: String, required: true },
2424
body: { type: String, required: true },
2525
url: { type: String, required: true },
26-
version: { type: String, required: true, default: version }
26+
version: { type: String, required: true, default: version },
27+
versionNumber: { type: Number, required: true, default: version.replace(/\.x$/, '') }
2728
});
2829
contentSchema.index({ title: 'text', body: 'text' });
2930
const Content = mongoose.model('Content', contentSchema, 'Content');

0 commit comments

Comments
 (0)