publicstring commited on
Commit
d8ee931
·
verified ·
1 Parent(s): d596a2a

Update app.js

Browse files
Files changed (1) hide show
  1. app.js +2 -2
app.js CHANGED
@@ -5,11 +5,11 @@ import { WebSocketServer, WebSocket } from 'ws';
5
  import { v4 as uuidv4 } from 'uuid';
6
  // Make sure this points to the compiled mechanics.js file in your build output,
7
  // or the JS version of your mechanics file.
8
- import { resolveCombat, getDerivedStats, breedOffspring, INITIAL_STATE } from './src/lib/mechanics.js';
9
 
10
  const app = express();
11
  // Hugging Face Spaces and other cloud PaaS use process.env.PORT (HF uses 7860)
12
- const PORT = process.env.PORT || 3000;
13
 
14
  // Enable CORS so your separate frontend can communicate
15
  app.use(cors({
 
5
  import { v4 as uuidv4 } from 'uuid';
6
  // Make sure this points to the compiled mechanics.js file in your build output,
7
  // or the JS version of your mechanics file.
8
+ import { resolveCombat, getDerivedStats, breedOffspring, INITIAL_STATE } from './mechanics.js';
9
 
10
  const app = express();
11
  // Hugging Face Spaces and other cloud PaaS use process.env.PORT (HF uses 7860)
12
+ const PORT = process.env.PORT || 7860;
13
 
14
  // Enable CORS so your separate frontend can communicate
15
  app.use(cors({