Skip to content

Instantly share code, notes, and snippets.

@dberry37388
Created April 7, 2014 19:34
Show Gist options
  • Save dberry37388/10036878 to your computer and use it in GitHub Desktop.
Save dberry37388/10036878 to your computer and use it in GitHub Desktop.
Sentry::getUserRepository()->findById(Sentry::getUser()->id);
object(Vertexhs\Users\Models\User)#802 (24) { ["table":protected]=> string(5) "users" ["guarded":protected]=> array(4) { [0]=> string(2) "id" [1]=> string(10) "created_at" [2]=> string(10) "updated_at" [3]=> string(9) "activated" } ["permissionsInstance":protected]=> NULL ["loginNames":protected]=> array(1) { [0]=> string(5) "email" } ["with":protected]=> array(1) { [0]=> string(16) "values.attribute" } ["eavNamespace":protected]=> string(14) "platform/users" ["valueRelation":protected]=> string(6) "values" ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(10) { ["id"]=> int(1) ["email"]=> string(25) "daniel.berry@vertexhs.com" ["password"]=> string(60) "$2y$10$ptKAysVjpyy05EwFOY9hsuIQO0uE4z5r9UkGT1N3jp//EiazKeyci" ["persistence_codes"]=> string(316) "["zJAoLHFa5yIjKTjRKqzaX3vIraJG23d6","nYKXWAqM7btmeW8qgB8wajSSc35SRzeO","uU0P1boDZAiwr4jBBzXoSDQW6J1iYRw1","wjv8xdVSzk3uluRRUgVimRrtVYfvfnjw","GKNfTg7IAkv4IAMPpVlLKf7vWhECCOHa","SigbRbEquDez3WypwXtKmKgsJbeON9Tv","fAhEP9DDnFXQyNpdExlaT4etSgsyGgCY","dvU1xDXPcdkLAekR1i9GcaspNIrYK2vb","pXBXVJIKBCFjnMvM1OgGcnvhK9Akh087"]" ["permissions"]=> string(0) "" ["last_login"]=> string(19) "2014-04-07 19:31:59" ["first_name"]=> string(6) "Daniel" ["last_name"]=> string(5) "Berry" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-07 19:31:59" } ["original":protected]=> array(10) { ["id"]=> int(1) ["email"]=> string(25) "daniel.berry@vertexhs.com" ["password"]=> string(60) "$2y$10$ptKAysVjpyy05EwFOY9hsuIQO0uE4z5r9UkGT1N3jp//EiazKeyci" ["persistence_codes"]=> string(316) "["zJAoLHFa5yIjKTjRKqzaX3vIraJG23d6","nYKXWAqM7btmeW8qgB8wajSSc35SRzeO","uU0P1boDZAiwr4jBBzXoSDQW6J1iYRw1","wjv8xdVSzk3uluRRUgVimRrtVYfvfnjw","GKNfTg7IAkv4IAMPpVlLKf7vWhECCOHa","SigbRbEquDez3WypwXtKmKgsJbeON9Tv","fAhEP9DDnFXQyNpdExlaT4etSgsyGgCY","dvU1xDXPcdkLAekR1i9GcaspNIrYK2vb","pXBXVJIKBCFjnMvM1OgGcnvhK9Akh087"]" ["permissions"]=> string(0) "" ["last_login"]=> string(19) "2014-04-07 19:31:59" ["first_name"]=> string(6) "Daniel" ["last_name"]=> string(5) "Berry" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-07 19:31:59" } ["relations":protected]=> array(2) { ["values"]=> object(Illuminate\Database\Eloquent\Collection)#804 (1) { ["items":protected]=> array(0) { } } ["groups"]=> object(Illuminate\Database\Eloquent\Collection)#814 (1) { ["items":protected]=> array(1) { [0]=> object(Cartalyst\Sentry\Groups\EloquentGroup)#809 (20) { ["table":protected]=> string(6) "groups" ["fillable":protected]=> array(3) { [0]=> string(4) "slug" [1]=> string(4) "name" [2]=> string(11) "permissions" } ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(6) { ["id"]=> int(1) ["slug"]=> string(5) "admin" ["name"]=> string(5) "Admin" ["permissions"]=> string(14) "{"admin":true}" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-01 14:03:47" } ["original":protected]=> array(10) { ["id"]=> int(1) ["slug"]=> string(5) "admin" ["name"]=> string(5) "Admin" ["permissions"]=> string(14) "{"admin":true}" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-01 14:03:47" ["pivot_user_id"]=> int(1) ["pivot_group_id"]=> int(1) ["pivot_created_at"]=> string(19) "2014-04-03 00:00:00" ["pivot_updated_at"]=> string(19) "2014-04-03 00:00:00" } ["relations":protected]=> array(1) { ["pivot"]=> object(Illuminate\Database\Eloquent\Relations\Pivot)#812 (23) { ["parent":protected]=> object(Vertexhs\Users\Models\User)#796 (24) { ["table":protected]=> string(5) "users" ["guarded":protected]=> array(4) { [0]=> string(2) "id" [1]=> string(10) "created_at" [2]=> string(10) "updated_at" [3]=> string(9) "activated" } ["permissionsInstance":protected]=> NULL ["loginNames":protected]=> array(1) { [0]=> string(5) "email" } ["with":protected]=> array(2) { [0]=> string(16) "values.attribute" [1]=> string(16) "values.attribute" } ["eavNamespace":protected]=> string(14) "platform/users" ["valueRelation":protected]=> string(6) "values" ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(0) { } ["original":protected]=> array(0) { } ["relations":protected]=> array(0) { } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["fillable":protected]=> array(0) { } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["exists"]=> bool(false) ["softDelete":protected]=> bool(false) } ["foreignKey":protected]=> string(7) "user_id" ["otherKey":protected]=> string(8) "group_id" ["guarded":protected]=> array(0) { } ["connection":protected]=> NULL ["table":protected]=> string(12) "groups_users" ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(4) { ["user_id"]=> int(1) ["group_id"]=> int(1) ["created_at"]=> string(19) "2014-04-03 00:00:00" ["updated_at"]=> string(19) "2014-04-03 00:00:00" } ["original":protected]=> array(0) { } ["relations":protected]=> array(0) { } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["fillable":protected]=> array(0) { } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) } } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["guarded":protected]=> array(1) { [0]=> string(1) "*" } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) } } } } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["fillable":protected]=> array(0) { } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) }
Sentry::getUser();
object(Cartalyst\Sentry\Users\EloquentUser)#442 (22) { ["table":protected]=> string(5) "users" ["fillable":protected]=> array(5) { [0]=> string(5) "email" [1]=> string(8) "password" [2]=> string(11) "permissions" [3]=> string(10) "first_name" [4]=> string(9) "last_name" } ["permissionsInstance":protected]=> NULL ["loginNames":protected]=> array(1) { [0]=> string(5) "email" } ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(10) { ["id"]=> int(1) ["email"]=> string(25) "daniel.berry@vertexhs.com" ["password"]=> string(60) "$2y$10$ptKAysVjpyy05EwFOY9hsuIQO0uE4z5r9UkGT1N3jp//EiazKeyci" ["persistence_codes"]=> string(316) "["zJAoLHFa5yIjKTjRKqzaX3vIraJG23d6","nYKXWAqM7btmeW8qgB8wajSSc35SRzeO","uU0P1boDZAiwr4jBBzXoSDQW6J1iYRw1","wjv8xdVSzk3uluRRUgVimRrtVYfvfnjw","GKNfTg7IAkv4IAMPpVlLKf7vWhECCOHa","SigbRbEquDez3WypwXtKmKgsJbeON9Tv","fAhEP9DDnFXQyNpdExlaT4etSgsyGgCY","dvU1xDXPcdkLAekR1i9GcaspNIrYK2vb","pXBXVJIKBCFjnMvM1OgGcnvhK9Akh087"]" ["permissions"]=> string(0) "" ["last_login"]=> string(19) "2014-04-07 19:31:59" ["first_name"]=> string(6) "Daniel" ["last_name"]=> string(5) "Berry" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-07 19:31:59" } ["original":protected]=> array(10) { ["id"]=> int(1) ["email"]=> string(25) "daniel.berry@vertexhs.com" ["password"]=> string(60) "$2y$10$ptKAysVjpyy05EwFOY9hsuIQO0uE4z5r9UkGT1N3jp//EiazKeyci" ["persistence_codes"]=> string(316) "["zJAoLHFa5yIjKTjRKqzaX3vIraJG23d6","nYKXWAqM7btmeW8qgB8wajSSc35SRzeO","uU0P1boDZAiwr4jBBzXoSDQW6J1iYRw1","wjv8xdVSzk3uluRRUgVimRrtVYfvfnjw","GKNfTg7IAkv4IAMPpVlLKf7vWhECCOHa","SigbRbEquDez3WypwXtKmKgsJbeON9Tv","fAhEP9DDnFXQyNpdExlaT4etSgsyGgCY","dvU1xDXPcdkLAekR1i9GcaspNIrYK2vb","pXBXVJIKBCFjnMvM1OgGcnvhK9Akh087"]" ["permissions"]=> string(0) "" ["last_login"]=> string(19) "2014-04-07 19:31:59" ["first_name"]=> string(6) "Daniel" ["last_name"]=> string(5) "Berry" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-07 19:31:59" } ["relations":protected]=> array(1) { ["groups"]=> object(Illuminate\Database\Eloquent\Collection)#453 (1) { ["items":protected]=> array(1) { [0]=> object(Cartalyst\Sentry\Groups\EloquentGroup)#449 (20) { ["table":protected]=> string(6) "groups" ["fillable":protected]=> array(3) { [0]=> string(4) "slug" [1]=> string(4) "name" [2]=> string(11) "permissions" } ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(6) { ["id"]=> int(1) ["slug"]=> string(5) "admin" ["name"]=> string(5) "Admin" ["permissions"]=> string(14) "{"admin":true}" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-01 14:03:47" } ["original":protected]=> array(10) { ["id"]=> int(1) ["slug"]=> string(5) "admin" ["name"]=> string(5) "Admin" ["permissions"]=> string(14) "{"admin":true}" ["created_at"]=> string(19) "2014-04-01 14:03:47" ["updated_at"]=> string(19) "2014-04-01 14:03:47" ["pivot_user_id"]=> int(1) ["pivot_group_id"]=> int(1) ["pivot_created_at"]=> string(19) "2014-04-03 00:00:00" ["pivot_updated_at"]=> string(19) "2014-04-03 00:00:00" } ["relations":protected]=> array(1) { ["pivot"]=> object(Illuminate\Database\Eloquent\Relations\Pivot)#451 (23) { ["parent":protected]=> object(Cartalyst\Sentry\Users\EloquentUser)#438 (22) { ["table":protected]=> string(5) "users" ["fillable":protected]=> array(5) { [0]=> string(5) "email" [1]=> string(8) "password" [2]=> string(11) "permissions" [3]=> string(10) "first_name" [4]=> string(9) "last_name" } ["permissionsInstance":protected]=> NULL ["loginNames":protected]=> array(1) { [0]=> string(5) "email" } ["connection":protected]=> NULL ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(0) { } ["original":protected]=> array(0) { } ["relations":protected]=> array(0) { } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["guarded":protected]=> array(1) { [0]=> string(1) "*" } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(false) ["softDelete":protected]=> bool(false) } ["foreignKey":protected]=> string(7) "user_id" ["otherKey":protected]=> string(8) "group_id" ["guarded":protected]=> array(0) { } ["connection":protected]=> NULL ["table":protected]=> string(12) "groups_users" ["primaryKey":protected]=> string(2) "id" ["perPage":protected]=> int(15) ["incrementing"]=> bool(true) ["timestamps"]=> bool(true) ["attributes":protected]=> array(4) { ["user_id"]=> int(1) ["group_id"]=> int(1) ["created_at"]=> string(19) "2014-04-03 00:00:00" ["updated_at"]=> string(19) "2014-04-03 00:00:00" } ["original":protected]=> array(0) { } ["relations":protected]=> array(0) { } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["fillable":protected]=> array(0) { } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) } } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["guarded":protected]=> array(1) { [0]=> string(1) "*" } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) } } } } ["hidden":protected]=> array(0) { } ["visible":protected]=> array(0) { } ["appends":protected]=> array(0) { } ["guarded":protected]=> array(1) { [0]=> string(1) "*" } ["dates":protected]=> array(0) { } ["touches":protected]=> array(0) { } ["observables":protected]=> array(0) { } ["with":protected]=> array(0) { } ["exists"]=> bool(true) ["softDelete":protected]=> bool(false) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment