Open vzsg opened 7 years ago
@LoganWright any ideas here?
I vaguely remember this being related to an ambiguity that we couldn't resolve when determining if we should init a single object or an array of objects.
let user: User = try row.get("user")
let user: [User] = try row.get("users")
This is an older issue I forgot to report, but still happening with the latest versions of the framework. It's easiest to reproduce with Fluent, but the underlying issue is here.
Consider an entity that has a Bytes property inside, and its
init(row:)
initializer.The linked file works, but if line 16 was written naively as one would expect to work:
A cryptic error is thrown instead:
Which suggests that for some dark reason, the function tried to convert the bytes SD into a single byte.