From 69a3328d1eecbd883fdacf4850a8eacd63ad0157 Mon Sep 17 00:00:00 2001 From: "Alexandre \"Moutarde\" S" Date: Sat, 18 Aug 2018 19:30:58 +0200 Subject: [PATCH 1/2] Fix Hash namespace Laravel report an error if using Hash and not \Hash --- app/Http/Controllers/Admin/Dashboard.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/Admin/Dashboard.php b/app/Http/Controllers/Admin/Dashboard.php index 1bfc0ed2..2d317cf1 100755 --- a/app/Http/Controllers/Admin/Dashboard.php +++ b/app/Http/Controllers/Admin/Dashboard.php @@ -28,7 +28,7 @@ public function showChangePassword(){ public function doChangePassword(){ - if (Hash::check(\Request('current_password'), \Auth::user()->password)) { + if (\Hash::check(\Request('current_password'), \Auth::user()->password)) { $new1 = \Request('new_password'); $new2 = \Request('new_password_repeat'); if($new1 == $new2){ From a00c7ed4e0bbab637b1d0cabdfcac18f90b152d3 Mon Sep 17 00:00:00 2001 From: "Alexandre \"Moutarde\" S" Date: Mon, 17 Sep 2018 05:18:36 +0200 Subject: [PATCH 2/2] Do some cleaning (#2) * Remove Laravel duplicate readme * add IDE specific to gitignore * Declare facades with full namespace It's cleaner and works with more IDE to find methods. * Rename readme.md to README.md * Add missing empty line --- .gitignore | 6 ++ README.md | 2 +- app/Http/Controllers/HomeController.php | 2 +- app/Http/Controllers/PayPalTestController.php | 3 +- app/Order.php | 2 +- app/Server.php | 2 +- readme.md | 59 ------------------- 7 files changed, 12 insertions(+), 64 deletions(-) delete mode 100755 readme.md diff --git a/.gitignore b/.gitignore index 939fbbaf..e6ebd363 100755 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,9 @@ Homestead.json # Rocketeer PHP task runner and deployment package. https://github.com/rocketeers/rocketeer .rocketeer/ + +# IDE specific +*.iml +*.iws +*.ipr +.idea/ diff --git a/README.md b/README.md index 5e97794c..781894a4 100755 --- a/README.md +++ b/README.md @@ -1 +1 @@ -# Backend \ No newline at end of file +# Backend diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 90b7f8a2..e7b6b719 100755 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -5,7 +5,7 @@ use Illuminate\Http\Request; use App\Category; use App\Order; -use Log; +use Illuminate\Support\Facades\Log; class HomeController extends Controller { diff --git a/app/Http/Controllers/PayPalTestController.php b/app/Http/Controllers/PayPalTestController.php index 07a558d3..b73e2113 100755 --- a/app/Http/Controllers/PayPalTestController.php +++ b/app/Http/Controllers/PayPalTestController.php @@ -15,8 +15,9 @@ use PayPal\Api\Transaction; use PayPal\Api\PaymentExecution; use Andrew\PaypalIPN\PaypalIPNListener; -use Log; use App\Order; +use Illuminate\Support\Facades\Log; + class PayPalTestController extends Controller { public function index(){ diff --git a/app/Order.php b/app/Order.php index 14ced20f..c92f5cd7 100755 --- a/app/Order.php +++ b/app/Order.php @@ -3,7 +3,7 @@ namespace App; use Illuminate\Database\Eloquent\Model; -use DB; +use Illuminate\Support\Facades\DB; use \DiscordWebhooks\Client; use \DiscordWebhooks\Embed; diff --git a/app/Server.php b/app/Server.php index 3a880a22..92998b37 100755 --- a/app/Server.php +++ b/app/Server.php @@ -3,7 +3,7 @@ namespace App; use Illuminate\Database\Eloquent\Model; -use Log; +use Illuminate\Support\Facades\Log; class Server extends Model { diff --git a/readme.md b/readme.md deleted file mode 100755 index 5e90f480..00000000 --- a/readme.md +++ /dev/null @@ -1,59 +0,0 @@ -

- -

-Build Status -Total Downloads -Latest Stable Version -License -

- -## About Laravel - -Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as: - -- [Simple, fast routing engine](https://laravel.com/docs/routing). -- [Powerful dependency injection container](https://laravel.com/docs/container). -- Multiple back-ends for [session](https://laravel.com/docs/session) and [cache](https://laravel.com/docs/cache) storage. -- Expressive, intuitive [database ORM](https://laravel.com/docs/eloquent). -- Database agnostic [schema migrations](https://laravel.com/docs/migrations). -- [Robust background job processing](https://laravel.com/docs/queues). -- [Real-time event broadcasting](https://laravel.com/docs/broadcasting). - -Laravel is accessible, yet powerful, providing tools needed for large, robust applications. - -## Learning Laravel - -Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of any modern web application framework, making it a breeze to get started learning the framework. - -If you're not in the mood to read, [Laracasts](https://laracasts.com) contains over 1100 video tutorials on a range of topics including Laravel, modern PHP, unit testing, JavaScript, and more. Boost the skill level of yourself and your entire team by digging into our comprehensive video library. - -## Laravel Sponsors - -We would like to extend our thanks to the following sponsors for helping fund on-going Laravel development. If you are interested in becoming a sponsor, please visit the Laravel [Patreon page](https://patreon.com/taylorotwell): - -- **[Vehikl](https://vehikl.com/)** -- **[Tighten Co.](https://tighten.co)** -- **[Kirschbaum Development Group](https://kirschbaumdevelopment.com)** -- **[British Software Development](https://www.britishsoftware.co)** -- [Fragrantica](https://www.fragrantica.com) -- [SOFTonSOFA](https://softonsofa.com/) -- [User10](https://user10.com) -- [Soumettre.fr](https://soumettre.fr/) -- [CodeBrisk](https://codebrisk.com) -- [1Forge](https://1forge.com) -- [TECPRESSO](https://tecpresso.co.jp/) -- [Pulse Storm](http://www.pulsestorm.net/) -- [Runtime Converter](http://runtimeconverter.com/) -- [WebL'Agence](https://weblagence.com/) - -## Contributing - -Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions). - -## Security Vulnerabilities - -If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [taylor@laravel.com](mailto:taylor@laravel.com). All security vulnerabilities will be promptly addressed. - -## License - -The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).