Subject: | bug in synopsis |
my $user = $new->schema->resultset('User')->new_result({ %$user_info });
$new->schema->current_user_id($user->id) if (defined $user_info);
The first line creates a new DBIC result object without inserting it
into the database.
The id method call in the second line will return undef because of that.