Skip to content

Commit c5ae1ac

Browse files
committed
Merge branch 'express-5-8529' of github.com:sagemathinc/cocalc into express-5-8529
2 parents 6623f79 + fe1c96c commit c5ae1ac

File tree

5 files changed

+7
-10
lines changed

5 files changed

+7
-10
lines changed

src/.claude/settings.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
"Bash(pnpm i18n:*:*)",
3333
"Bash(pnpm info:*)",
3434
"Bash(pnpm list:*)",
35-
"Bash(pnpm list:*)",
3635
"Bash(pnpm remove:*)",
3736
"Bash(pnpm run:*)",
3837
"Bash(pnpm test:*)",

src/packages/hub/proxy/handle-upgrade.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,14 @@
22

33
import { createProxyServer, type ProxyServer } from "http-proxy-3";
44
import LRU from "lru-cache";
5-
6-
import basePath from "@cocalc/backend/base-path";
7-
import getLogger from "@cocalc/hub/logger";
85
import { getEventListeners } from "node:events";
9-
import { proxyConatWebsocket } from "./proxy-conat";
6+
import getLogger from "@cocalc/hub/logger";
107
import stripRememberMeCookie from "./strip-remember-me-cookie";
118
import { getTarget } from "./target";
129
import { stripBasePath } from "./util";
1310
import { versionCheckFails } from "./version";
11+
import { proxyConatWebsocket } from "./proxy-conat";
12+
import basePath from "@cocalc/backend/base-path";
1413

1514
const LISTENERS_HACK = true;
1615

src/packages/hub/proxy/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55

66
import { Application } from "express";
77

8-
import base_path from "@cocalc/backend/base-path";
9-
import { ProjectControlFunction } from "@cocalc/server/projects/control";
108
import getLogger from "../logger";
119
import initRequest from "./handle-request";
1210
import initUpgrade from "./handle-upgrade";
11+
import base_path from "@cocalc/backend/base-path";
12+
import { ProjectControlFunction } from "@cocalc/server/projects/control";
1313

1414
const logger = getLogger("proxy");
1515

src/packages/hub/servers/app/next.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ import basePath from "@cocalc/backend/base-path";
1616
import { getLogger } from "@cocalc/hub/logger";
1717
import handleRaw from "@cocalc/next/lib/share/handle-raw";
1818
import { callback2 } from "@cocalc/util/async-utils";
19-
import { separate_file_extension } from "@cocalc/util/misc";
2019
import { database } from "../database";
2120
import createLandingRedirect from "./landing-redirect";
2221
import shareRedirect from "./share-redirect";
22+
import { separate_file_extension } from "@cocalc/util/misc";
2323

2424
export default async function init(app: Application) {
2525
const winston = getLogger("nextjs");

src/packages/project/directory-listing.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,14 @@ Browser client code only uses this through the websocket anyways.
1818
*/
1919

2020
import { Router } from "express";
21-
import { join } from "node:path";
2221

2322
import getListing from "@cocalc/backend/get-listing";
2423

2524
export default function init(): Router {
2625
const base = "/.smc/directory_listing/";
2726
const router = Router();
2827

29-
router.get(join(base, "{*splat}"), async (req, res) => {
28+
router.get(base + "{*splat}", async (req, res) => {
3029
// decodeURIComponent because decodeURI(misc.encode_path('asdf/te #1/')) != 'asdf/te #1/'
3130
// https://github.com/sagemathinc/cocalc/issues/2400
3231
const path = decodeURIComponent(req.path.slice(base.length).trim());

0 commit comments

Comments
 (0)