Skip to content

Commit

Permalink
Fixed compatibility with frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
TheDogHusky committed Jul 23, 2024
1 parent 19acbdb commit b5d6bf8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/api/v1/random.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ router.get('/:type', (req, res) => {

const image = files[Math.floor(Math.random() * files.length)];
return res.status(200).json({
"url": getBaseURL(req) + "/images/" + type + "/" + image
"url": getBaseURL(req) + "/images/" + type + "s/" + image
});
});

Expand Down
2 changes: 1 addition & 1 deletion src/structures/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export default class App {
this.logger.info(`${req.method} @${req.originalUrl} - ${res.statusCode} (${utils.timingColor(ms)})`, "App");
});
const api = Api(this.logger);
this.app.use('/api', api);
this.app.use(api);
};

public listen() {
Expand Down
8 changes: 4 additions & 4 deletions static/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="/main.css">
<link rel="stylesheet" href="/api//main.css">
<title>NekoNya-Storage</title>
<link rel="icon" href="/favicon.ico">
<link rel="manifest" href="/manifest.webmanifest">
<link rel="robots" href="/robots.txt">
<link rel="icon" href="/api/favicon.ico">
<link rel="manifest" href="/api/manifest.webmanifest">
<link rel="robots" href="/api//robots.txt">
</head>
<body>
<div class="container">
Expand Down

0 comments on commit b5d6bf8

Please sign in to comment.