upfynai-code 2.5.1 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "upfynai-code",
3
- "version": "2.5.1",
3
+ "version": "2.6.0",
4
4
  "description": "Visual AI coding interface for Claude Code, Cursor & Codex. Canvas whiteboard, multi-agent chat, terminal, git, voice assistant. Self-host locally or connect to cli.upfyn.com for remote access.",
5
5
  "type": "module",
6
6
  "main": "server/index.js",
@@ -98,7 +98,6 @@
98
98
  "mime-types": "^3.0.1",
99
99
  "multer": "^2.0.2",
100
100
  "node-cron": "^4.2.1",
101
- "node-fetch": "^2.7.0",
102
101
  "pdfjs-dist": "^5.4.624",
103
102
  "postcss": "^8.4.32",
104
103
  "razorpay": "^2.9.6",
@@ -121,18 +120,13 @@
121
120
  "zustand": "^5.0.11"
122
121
  },
123
122
  "optionalDependencies": {
124
- "bcrypt": "^6.0.0",
125
- "better-sqlite3": "^12.2.0",
126
- "node-pty": "^1.1.0-beta34",
127
- "sqlite": "^5.1.1",
128
- "sqlite3": "^5.1.7"
123
+ "node-pty": "^1.1.0-beta34"
129
124
  },
130
125
  "devDependencies": {
131
126
  "@types/node": "^22.19.7",
132
127
  "@types/react": "^18.2.43",
133
128
  "@types/react-dom": "^18.2.17",
134
129
  "lightningcss": "^1.31.1",
135
- "node-gyp": "^10.0.0",
136
130
  "typescript": "^5.9.3"
137
131
  }
138
132
  }
package/server/cli.js CHANGED
@@ -1,4 +1,4 @@
1
- #!/usr/bin/env node
1
+ #!/usr/bin/env node
2
2
  /**
3
3
  * Upfyn-Code CLI
4
4
  * by Thinqmesh Technologies
@@ -227,6 +227,20 @@ CREATE TABLE IF NOT EXISTS workflow_runs (
227
227
  CREATE INDEX IF NOT EXISTS idx_workflow_runs_workflow_id ON workflow_runs(workflow_id);
228
228
  CREATE INDEX IF NOT EXISTS idx_workflow_runs_user_id ON workflow_runs(user_id);
229
229
  CREATE INDEX IF NOT EXISTS idx_workflow_runs_status ON workflow_runs(status);
230
+
231
+ CREATE TABLE IF NOT EXISTS user_sandboxes (
232
+ id INTEGER PRIMARY KEY AUTOINCREMENT,
233
+ user_id INTEGER NOT NULL UNIQUE,
234
+ sandbox_path TEXT NOT NULL,
235
+ created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
236
+ last_accessed DATETIME DEFAULT CURRENT_TIMESTAMP,
237
+ disk_usage_bytes INTEGER DEFAULT 0,
238
+ is_active BOOLEAN DEFAULT 1,
239
+ FOREIGN KEY (user_id) REFERENCES users(id) ON DELETE CASCADE
240
+ );
241
+
242
+ CREATE INDEX IF NOT EXISTS idx_user_sandboxes_user_id ON user_sandboxes(user_id);
243
+ CREATE INDEX IF NOT EXISTS idx_user_sandboxes_active ON user_sandboxes(is_active);
230
244
  `;
231
245
 
232
246
  // ─── Migrations ─────────────────────────────────────────────────────────────────
@@ -368,8 +382,8 @@ const userDb = {
368
382
  getUserByUsername: async (username) => {
369
383
  const lower = (username || '').toLowerCase();
370
384
  const result = await db.execute({
371
- sql: 'SELECT * FROM users WHERE (LOWER(username) = ? OR LOWER(email) = ? OR phone = ?) AND is_active = 1',
372
- args: [lower, lower, username]
385
+ sql: 'SELECT * FROM users WHERE (LOWER(username) = ? OR LOWER(email) = ? OR phone = ? OR LOWER(user_code) = ?) AND is_active = 1',
386
+ args: [lower, lower, username, lower]
373
387
  });
374
388
  return getRow(result);
375
389
  },