Polish Bean Bro setup errors and preserve empty plan names
Test and deploy / test-and-deploy (push) Successful in 1m22s
Test and deploy / test-and-deploy (push) Successful in 1m22s
This commit is contained in:
1 parent
8c21750356
commit
f2abdcefe1
2 files changed
+2
-2
No files matched your search
+1
-1
@@ -38,7 +38,7 @@ export async function pickModel(preferred = null) {
|
|||||||
|
|
||||||
/** Consistent error for "the server has no usable model" across features. */
|
/** Consistent error for "the server has no usable model" across features. */
|
||||||
export function noModelError() {
|
export function noModelError() {
|
||||||
const err = new Error("No LLM model is configured on the server.");
|
const err = new Error("Bean Bro is not configured on the server. An admin can choose a provider in Admin → Bean Bro.");
|
||||||
err.code = "no_model";
|
err.code = "no_model";
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
+1
-1
@@ -277,7 +277,7 @@ export async function savePlanRevision(db, userId, id, body) {
|
|||||||
name =
|
name =
|
||||||
body.name === undefined
|
body.name === undefined
|
||||||
? existing.name
|
? existing.name
|
||||||
: String(body.name).trim().slice(0, 120);
|
: String(body.name ?? "").trim().slice(0, 120);
|
||||||
const planning = (p) => {
|
const planning = (p) => {
|
||||||
const { assistant, roastDay, ...rest } = p;
|
const { assistant, roastDay, ...rest } = p;
|
||||||
return rest;
|
return rest;
|
||||||
|
|||||||
Reference in new issue
Block a user