@PoetaWD
Try:
if( $u->exists() ) {
// $u exists
} else {
// $u does not exist
}Also, you can use this to look up a user by id (it’s just shorthand for what you already wrote):
$u->get_by_id($userid);Finally, make sure you look through the DataMapper documentation, at http://stensi.com/datamapper/index.html
Good Luck, and if you have any questions, feel free to ask.