const executor = new PgExecutor({
name: "main",
context() {
const ctx = context();
return object({
pgSettings: "pgSettings" != null ? ctx.get("pgSettings") : constant(null),
withPgClient: ctx.get("withPgClient")
});
}
});
The expression "pgSettings" != null ? ctx.get("pgSettings") : constant(null) can be replaced with just ctx.get("pgSettings").