{"action":"created","issue":{"url":"https://api.github.com/repos/eveseat/web/issues/159","repository_url":"https://api.github.com/repos/eveseat/web","labels_url":"https://api.github.com/repos/eveseat/web/issues/159/labels{/name}","comments_url":"https://api.github.com/repos/eveseat/web/issues/159/comments","events_url":"https://api.github.com/repos/eveseat/web/issues/159/events","html_url":"https://github.com/eveseat/web/pull/159","id":322587882,"number":159,"title":"fix: Roleconfiguration template tried to access removed property","user":{"login":"Inkura","id":31927152,"avatar_url":"https://avatars2.githubusercontent.com/u/31927152?v=4","gravatar_id":"","url":"https://api.github.com/users/Inkura","html_url":"https://github.com/Inkura","followers_url":"https://api.github.com/users/Inkura/followers","following_url":"https://api.github.com/users/Inkura/following{/other_user}","gists_url":"https://api.github.com/users/Inkura/gists{/gist_id}","starred_url":"https://api.github.com/users/Inkura/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Inkura/subscriptions","organizations_url":"https://api.github.com/users/Inkura/orgs","repos_url":"https://api.github.com/users/Inkura/repos","events_url":"https://api.github.com/users/Inkura/events{/privacy}","received_events_url":"https://api.github.com/users/Inkura/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-05-13T12:00:42Z","updated_at":"2018-05-13T17:28:48Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/eveseat/web/pulls/159","html_url":"https://github.com/eveseat/web/pull/159","diff_url":"https://github.com/eveseat/web/pull/159.diff","patch_url":"https://github.com/eveseat/web/pull/159.patch"},"body":"The view `eveseat/web/src/resources/views/configuration/access/edit.blade.php` tries to access the removed relationship `\\Seat\\Web\\Models\\Acl\\Role::users()`.\r\n\r\nThis causes an error and the roles can not be edited.\r\n\r\n## Steps to reproduce\r\n* Log in as admin\r\n* Settings -> Access Management \r\n* Try to edit a role\r\n\r\n## Steps to fix\r\n* Access the groups property and count its users instead\r\n\r\n## Stacktrace\r\n```\r\n[2018-05-13 10:33:05] local.ERROR: count(): Parameter must be an array or an object that implements Countable (View: /var/www/vhosts/seat.flo.pcsg/packages/eveseat/web/src/resources/views/configuration/access/edit.blade.php) {\"userId\":1,\"email\":\"admin@seat.local\",\"exception\":\"[object] (ErrorException(code: 0): count(): Parameter must be an array or an object that implements Countable (View: /var/www/vhosts/seat.flo.pcsg/packages/eveseat/web/src/resources/views/configuration/access/edit.blade.php) at /var/www/vhosts/seat.flo.pcsg/storage/framework/views/a4f490450b59b6b72a486d3204d22c74b4b40bc9.php:312, ErrorException(code: 0): count(): Parameter must be an array or an object that implements Countable at /var/www/vhosts/seat.flo.pcsg/storage/framework/views/a4f490450b59b6b72a486d3204d22c74b4b40bc9.php:312)\r\n[stacktrace]\r\n#0 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php(45): Illuminate\\\\View\\\\Engines\\\\CompilerEngine->handleViewException(Object(ErrorException), 1)\r\n#1 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php(59): Illuminate\\\\View\\\\Engines\\\\PhpEngine->evaluatePath('/var/www/vhosts...', Array)\r\n#2 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/View.php(137): Illuminate\\\\View\\\\Engines\\\\CompilerEngine->get('/var/www/vhosts...', Array)\r\n#3 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/View.php(120): Illuminate\\\\View\\\\View->getContents()\r\n#4 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/View.php(85): Illuminate\\\\View\\\\View->renderContents()\r\n#5 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Http/Response.php(42): Illuminate\\\\View\\\\View->render()\r\n#6 /var/www/vhosts/seat.flo.pcsg/vendor/symfony/http-foundation/Response.php(201): Illuminate\\\\Http\\\\Response->setContent(Object(Illuminate\\\\View\\\\View))\r\n#7 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(724): Symfony\\\\Component\\\\HttpFoundation\\\\Response->__construct(Object(Illuminate\\\\View\\\\View))\r\n#8 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(698): Illuminate\\\\Routing\\\\Router::toResponse(Object(Illuminate\\\\Http\\\\Request), Object(Illuminate\\\\View\\\\View))\r\n#9 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(658): Illuminate\\\\Routing\\\\Router->prepareResponse(Object(Illuminate\\\\Http\\\\Request), Object(Illuminate\\\\View\\\\View))\r\n#10 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(30): Illuminate\\\\Routing\\\\Router->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#11 /var/www/vhosts/seat.flo.pcsg/packages/eveseat/web/src/Http/Middleware/Bouncer/Bouncer.php(56): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#12 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Seat\\\\Web\\\\Http\\\\Middleware\\\\Bouncer\\\\Bouncer->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure), 'superuser')\r\n#13 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#14 /var/www/vhosts/seat.flo.pcsg/packages/eveseat/web/src/Http/Middleware/Locale.php(44): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#15 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Seat\\\\Web\\\\Http\\\\Middleware\\\\Locale->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#16 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#17 /var/www/vhosts/seat.flo.pcsg/packages/eveseat/web/src/Http/Middleware/Authenticate.php(67): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#18 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Seat\\\\Web\\\\Http\\\\Middleware\\\\Authenticate->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#19 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#20 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php(41): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#21 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Routing\\\\Middleware\\\\SubstituteBindings->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#22 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#23 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/VerifyCsrfToken.php(67): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#24 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Foundation\\\\Http\\\\Middleware\\\\VerifyCsrfToken->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#25 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#26 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php(49): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#27 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\View\\\\Middleware\\\\ShareErrorsFromSession->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#28 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#29 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php(63): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#30 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Session\\\\Middleware\\\\StartSession->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#31 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#32 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/AddQueuedCookiesToResponse.php(37): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#33 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Cookie\\\\Middleware\\\\AddQueuedCookiesToResponse->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#34 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#35 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php(59): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#36 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Cookie\\\\Middleware\\\\EncryptCookies->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#37 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#38 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(102): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#39 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(660): Illuminate\\\\Pipeline\\\\Pipeline->then(Object(Closure))\r\n#40 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(635): Illuminate\\\\Routing\\\\Router->runRouteWithinStack(Object(Illuminate\\\\Routing\\\\Route), Object(Illuminate\\\\Http\\\\Request))\r\n#41 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(601): Illuminate\\\\Routing\\\\Router->runRoute(Object(Illuminate\\\\Http\\\\Request), Object(Illuminate\\\\Routing\\\\Route))\r\n#42 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Router.php(590): Illuminate\\\\Routing\\\\Router->dispatchToRoute(Object(Illuminate\\\\Http\\\\Request))\r\n#43 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(176): Illuminate\\\\Routing\\\\Router->dispatch(Object(Illuminate\\\\Http\\\\Request))\r\n#44 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(30): Illuminate\\\\Foundation\\\\Http\\\\Kernel->Illuminate\\\\Foundation\\\\Http\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#45 /var/www/vhosts/seat.flo.pcsg/vendor/fideloper/proxy/src/TrustProxies.php(56): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#46 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Fideloper\\\\Proxy\\\\TrustProxies->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#47 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#48 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(30): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#49 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Foundation\\\\Http\\\\Middleware\\\\TransformsRequest->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#50 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#51 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(30): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#52 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Foundation\\\\Http\\\\Middleware\\\\TransformsRequest->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#53 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#54 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ValidatePostSize.php(27): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#55 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Foundation\\\\Http\\\\Middleware\\\\ValidatePostSize->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#56 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#57 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/CheckForMaintenanceMode.php(46): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#58 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(149): Illuminate\\\\Foundation\\\\Http\\\\Middleware\\\\CheckForMaintenanceMode->handle(Object(Illuminate\\\\Http\\\\Request), Object(Closure))\r\n#59 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Routing/Pipeline.php(53): Illuminate\\\\Pipeline\\\\Pipeline->Illuminate\\\\Pipeline\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#60 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(102): Illuminate\\\\Routing\\\\Pipeline->Illuminate\\\\Routing\\\\{closure}(Object(Illuminate\\\\Http\\\\Request))\r\n#61 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(151): Illuminate\\\\Pipeline\\\\Pipeline->then(Object(Closure))\r\n#62 /var/www/vhosts/seat.flo.pcsg/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(116): Illuminate\\\\Foundation\\\\Http\\\\Kernel->sendRequestThroughRouter(Object(Illuminate\\\\Http\\\\Request))\r\n#63 /var/www/vhosts/seat.flo.pcsg/public/index.php(54): Illuminate\\\\Foundation\\\\Http\\\\Kernel->handle(Object(Illuminate\\\\Http\\\\Request))\r\n#64 {main}\r\n\"} \r\n```"},"comment":{"url":"https://api.github.com/repos/eveseat/web/issues/comments/388642761","html_url":"https://github.com/eveseat/web/pull/159#issuecomment-388642761","issue_url":"https://api.github.com/repos/eveseat/web/issues/159","id":388642761,"user":{"login":"leonjza","id":1148127,"avatar_url":"https://avatars3.githubusercontent.com/u/1148127?v=4","gravatar_id":"","url":"https://api.github.com/users/leonjza","html_url":"https://github.com/leonjza","followers_url":"https://api.github.com/users/leonjza/followers","following_url":"https://api.github.com/users/leonjza/following{/other_user}","gists_url":"https://api.github.com/users/leonjza/gists{/gist_id}","starred_url":"https://api.github.com/users/leonjza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leonjza/subscriptions","organizations_url":"https://api.github.com/users/leonjza/orgs","repos_url":"https://api.github.com/users/leonjza/repos","events_url":"https://api.github.com/users/leonjza/events{/privacy}","received_events_url":"https://api.github.com/users/leonjza/received_events","type":"User","site_admin":false},"created_at":"2018-05-13T17:28:48Z","updated_at":"2018-05-13T17:28:48Z","author_association":"OWNER","body":"Thank you for the pr! The correct way here would be to count the groups that have the role as roles are attached to a group now, and users are simply members of that group."}}
{"actor":{"display_login":"leonjza"}}