clear old code
This commit is contained in:
@@ -7,7 +7,6 @@ import { app, minioClient } from '@/app.ts';
|
|||||||
import { bucketName } from '@/modules/minio.ts';
|
import { bucketName } from '@/modules/minio.ts';
|
||||||
import { getContentType } from '@/utils/get-content-type.ts';
|
import { getContentType } from '@/utils/get-content-type.ts';
|
||||||
import { User } from '@/models/user.ts';
|
import { User } from '@/models/user.ts';
|
||||||
import { getContainerById } from '@/old-apps/container/module/get-container-file.ts';
|
|
||||||
import { router, error, checkAuth, writeEvents } from './router.ts';
|
import { router, error, checkAuth, writeEvents } from './router.ts';
|
||||||
import './index.ts';
|
import './index.ts';
|
||||||
import { handleRequest as PageProxy } from './page-proxy.ts';
|
import { handleRequest as PageProxy } from './page-proxy.ts';
|
||||||
@@ -190,30 +189,6 @@ router.post('/api/app/upload', async (req, res) => {
|
|||||||
pipeBusboy(req, res, busboy);
|
pipeBusboy(req, res, busboy);
|
||||||
});
|
});
|
||||||
|
|
||||||
router.get('/api/container/file/:id', async (req, res) => {
|
|
||||||
const id = req.params.id;
|
|
||||||
if (!id) {
|
|
||||||
res.end(error('id is required'));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const container = await getContainerById(id);
|
|
||||||
if (container.id) {
|
|
||||||
const code = container.code;
|
|
||||||
res.writeHead(200, {
|
|
||||||
'Content-Type': 'application/javascript; charset=utf-8',
|
|
||||||
'container-id': container.id,
|
|
||||||
});
|
|
||||||
res.end(code);
|
|
||||||
} else {
|
|
||||||
res.end(error('Container not found'));
|
|
||||||
}
|
|
||||||
|
|
||||||
res.writeHead(200, {
|
|
||||||
'Content-Type': 'application/json',
|
|
||||||
});
|
|
||||||
res.end(JSON.stringify(container));
|
|
||||||
});
|
|
||||||
|
|
||||||
router.all('/api/nocodb-test/router', async (req, res) => {
|
router.all('/api/nocodb-test/router', async (req, res) => {
|
||||||
res.writeHead(200, { 'Content-Type': 'application/json' });
|
res.writeHead(200, { 'Content-Type': 'application/json' });
|
||||||
|
|
||||||
|
|||||||
1
src/routes/light-code/index.ts
Normal file
1
src/routes/light-code/index.ts
Normal file
@@ -0,0 +1 @@
|
|||||||
|
import './list.ts'
|
||||||
Reference in New Issue
Block a user