chore(cli): formatting + version consistency
This commit is contained in:
parent
fdd556df83
commit
970061ff9d
15 changed files with 83 additions and 34 deletions
|
@ -31,6 +31,7 @@ export const initConfig = async () => {
|
|||
message: 'Where is your storage root directory?',
|
||||
validate: fs.pathExists
|
||||
}]);
|
||||
|
||||
config.storageDir = storageDir;
|
||||
}
|
||||
} else {
|
||||
|
@ -39,6 +40,7 @@ export const initConfig = async () => {
|
|||
message: 'Where is your storage root directory?',
|
||||
validate: fs.pathExists
|
||||
}]);
|
||||
|
||||
config.storageDir = storageDir;
|
||||
}
|
||||
|
||||
|
@ -66,6 +68,7 @@ export const initConfig = async () => {
|
|||
message: `Subpath for ${mediaType}/${assetType} (relative to storage root):`,
|
||||
default: defaultPath
|
||||
}]);
|
||||
|
||||
subpath = response.subpath;
|
||||
}
|
||||
|
||||
|
@ -161,6 +164,7 @@ const fetchGlobals = async () => {
|
|||
|
||||
if (!POSTGREST_URL || !POSTGREST_API_KEY) {
|
||||
console.warn('⚠️ Missing POSTGREST_URL or POSTGREST_API_KEY in env, skipping globals fetch.');
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
|
@ -176,9 +180,11 @@ const fetchGlobals = async () => {
|
|||
if (!res.ok) throw new Error(await res.text());
|
||||
|
||||
const data = await res.json();
|
||||
|
||||
return data[0] || {};
|
||||
} catch (err) {
|
||||
console.error('❌ Error fetching globals:', err.message);
|
||||
|
||||
return {};
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue