schema updated for camera

This commit is contained in:
2025-01-24 16:35:36 +05:30
parent 50e8d906f3
commit 5984f445f7
2 changed files with 3 additions and 3 deletions

4
.env
View File

@@ -1,4 +1,4 @@
MONGO_URI=mongodb://127.0.0.1:27017/
# MONGO_URI=mongodb://mongo/
# MONGO_URI=mongodb://127.0.0.1:27017/
MONGO_URI=mongodb://mongo/
API_PORT=5000
SOCKET_PORT=8000

View File

@@ -23,7 +23,7 @@ export interface Camera extends Document {
// Define the Mongoose Schema
const cameraSchema: Schema = new Schema({
userId: { type: String, unique: true },
userId: { type: String },
position: {
x: { type: Number, required: true },
y: { type: Number, required: true },