chore: bump glob

This commit is contained in:
cha0s 2024-01-13 01:59:17 -06:00
parent 04bcc4a230
commit 8f5a1707b2
2 changed files with 3 additions and 7 deletions

View File

@ -45,8 +45,7 @@
"@flecks/socket": "^2.0.3", "@flecks/socket": "^2.0.3",
"@humus/app": "^2.0.0", "@humus/app": "^2.0.0",
"debug": "4.3.1", "debug": "4.3.1",
"express": "^4.17.1", "express": "^4.17.1"
"glob": "^7.1.6"
}, },
"devDependencies": { "devDependencies": {
"@flecks/fleck": "^2.0.3" "@flecks/fleck": "^2.0.3"

View File

@ -5,11 +5,10 @@ import {
writeFile, writeFile,
} from 'fs/promises'; } from 'fs/promises';
import {join} from 'path'; import {join} from 'path';
import {promisify} from 'util';
import {createLoop, destroyLoop} from '@avocado/timing/server'; import {createLoop, destroyLoop} from '@avocado/timing/server';
import {D} from '@flecks/core'; import {D} from '@flecks/core';
import glob from 'glob'; import {glob} from '@flecks/core/server';
import createPlayerEntity from '../gen/player-entity'; import createPlayerEntity from '../gen/player-entity';
import createPlayerRoom from '../gen/player-room'; import createPlayerRoom from '../gen/player-room';
@ -18,8 +17,6 @@ import Player from './player';
const debug = D('@humus/universe/server/universe'); const debug = D('@humus/universe/server/universe');
const debugSilly = debug.extend('silly'); const debugSilly = debug.extend('silly');
const pglob = promisify(glob);
export default class Universe { export default class Universe {
$$flecks; $$flecks;
@ -134,7 +131,7 @@ export default class Universe {
await universe.loadOrCreateResource(); await universe.loadOrCreateResource();
const {Room} = flecks.avocado.resource.Resources; const {Room} = flecks.avocado.resource.Resources;
await Promise.all( await Promise.all(
(await pglob('**/*.room.json', {cwd: path})) (await glob('**/*.room.json', {cwd: path}))
.map(async (roomUri) => { .map(async (roomUri) => {
const qualified = `/${roomUri}`; const qualified = `/${roomUri}`;
try { try {