diff options
| author | Carson Fleming <cflems@cflems.net> | 2023-10-18 03:48:52 -0400 |
|---|---|---|
| committer | Carson Fleming <cflems@cflems.net> | 2023-10-18 03:48:52 -0400 |
| commit | 85f217f63e248ae0df44368a6a0d03620955f170 (patch) | |
| tree | d6d84084f8f2ad5a3fa0804ee576b492d9e33e7e /db/url-schema.js | |
| parent | adaf5b0fde4431eb186075e7921e2f0999e68dd9 (diff) | |
| download | fle.ms-85f217f63e248ae0df44368a6a0d03620955f170.tar.gz | |
Created initial backend architecture and redirection routes
Diffstat (limited to 'db/url-schema.js')
| -rw-r--r-- | db/url-schema.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/db/url-schema.js b/db/url-schema.js new file mode 100644 index 0000000..8392e3d --- /dev/null +++ b/db/url-schema.js @@ -0,0 +1,14 @@ +const mongoose = require('mongoose'); + +const UrlSchema = new mongoose.Schema({ + slug: { + type: mongoose.SchemaTypes.String, + required: true + }, + url: { + type: mongoose.SchemaTypes.String, + required: true + } +}); + +module.exports = mongoose.model('Url', UrlSchema); |
