Skip to content

Commit c45c36c

Browse files
committed
orm: improve an fkey error a bit
1 parent e8dbd2c commit c45c36c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

vlib/net/websocket/websocket_client.v

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const (
1616
)
1717

1818
pub struct ClientState {
19-
mut:
19+
pub mut:
2020
state State = .closed // current state of connection
2121
}
2222

vlib/v/gen/c/orm.v

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ fn (mut g Gen) write_orm_insert_with_last_ids(node ast.SqlStmtLine, connection_v
288288
}
289289
}
290290
if f_key == '' {
291-
verror('An field which holds an array, needs a fkey defined')
291+
verror('a field which holds an array, needs a fkey defined ("${sym.name}")')
292292
}
293293
fkeys << f_key
294294
info := sym.array_info()
@@ -911,7 +911,7 @@ fn (mut g Gen) write_orm_select(node ast.SqlExpr, connection_var_name string, le
911911
}
912912
// TODO: move to the ORM checker
913913
if fkey == '' {
914-
verror('An field which holds an array, needs a `fkey` defined')
914+
verror('fn field which holds an array, needs a `fkey` defined ("${sym.name}")')
915915
}
916916
info := sym.array_info()
917917
arr_typ := info.elem_type

0 commit comments

Comments
 (0)