Skip to content

Commit

Permalink
fix: Owner 默认为 80
Browse files Browse the repository at this point in the history
  • Loading branch information
SALTWOOD committed Nov 9, 2024
1 parent 500de4b commit 5923acf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/database/Cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export class ClusterEntity {

public port: number = 80;

public owner: number = 80;
public owner: number = 0;

public downReason: string = '';

Expand Down
6 changes: 1 addition & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,6 @@ import { Utilities } from './Utilities.js';
import { HttpRequest } from "./HttpRequest.js";
import fs from 'fs';

function createFolderIfNotExist(folder: string) {
if (!fs.existsSync(folder)) fs.mkdirSync(folder, { recursive: true });
}

function onStop(signal: string) {
server.db.close();
server.stats.forEach(stats => stats.stopAutoSave());
Expand All @@ -26,7 +22,7 @@ const requiredFolders = [
];

for (const folder of requiredFolders) {
createFolderIfNotExist(folder);
if (!fs.existsSync(folder)) fs.mkdirSync(folder, { recursive: true });
}

// 初始化配置
Expand Down

0 comments on commit 5923acf

Please sign in to comment.