garygreen / pretty-routes

Pretty routes for Laravel
655 stars 77 forks source link

Error on fresh install #63

Closed hosquiat closed 5 years ago

hosquiat commented 5 years ago

Not sure why this is happening but I get this error when I hit the /routes route:

Undefined index: OPTIONS (View: /application/vendor/garygreen/pretty-routes/views/routes.blade.php)

I'm running Laravel 5.8.*

hosquiat commented 5 years ago

Looks like the issue stems from the absense of a color for OPTIONS in file above:

https://github.com/garygreen/pretty-routes/blob/5d8431b990d07b6f74729b1982ee8232ed0dc537/views/routes.blade.php#L53

I made the change locally and was able to get the /routes page to load.

<?php $methodColours = ['GET' => 'success', 'HEAD' => 'default', 'OPTIONS' => 'default', 'POST' => 'primary', 'PUT' => 'warning', 'PATCH' => 'info', 'DELETE' => 'danger']; ?>