Hello!
I have an empty magma database (I'm using Keithy's ToDo tutorial application with Magma seasideHelper). This one: http://wiki.squeak.org/squeak/6021
So please get the latest version (7) so you can answer on my question :)
In the StMagmaDatabase->#createDefaultUser (which is temporary called from #findUserByEmail) I'm initializing a database and adding one user with 'todo@todo.tut' email:
| user |
self initialize.
user := StUser new.
user id: 1.
user email: 'todo@todo.tut'.
user userName: 'todo'.
user password: 'todo'.
self addUser: user.
then I'm trying to find user by email ('todo@todo.tz'). BUT... I'm getting a wrong result
user := self users where: [:each |
each read: #email at: 'todo.tz'.
].
user first explore.
user first returns the first user in MagmaCollection with the WRONG email ('todo@todo.tz').
So how can I get nil in this case? (because there is no user with such email in database).
Thanks.