fix: error message of Nix.select
This commit is contained in:
@@ -115,12 +115,7 @@ export const select = (obj: NixValue, attrpath: NixValue[]): NixValue => {
|
|||||||
if (!(key in attrs)) {
|
if (!(key in attrs)) {
|
||||||
throw new Error(`Attribute '${key}' not found`);
|
throw new Error(`Attribute '${key}' not found`);
|
||||||
}
|
}
|
||||||
const cur = force(attrs[forceString(attr)]);
|
const cur = forceAttrs(attrs[forceString(attr)]);
|
||||||
if (!isAttrs(cur)) {
|
|
||||||
// throw new Error(`Attribute '${forced_key}' not found`);
|
|
||||||
// FIXME: error
|
|
||||||
throw new Error(`Attribute not found`);
|
|
||||||
}
|
|
||||||
attrs = cur;
|
attrs = cur;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user