1234567891011121314151617181920212223242526272829303132333435 |
- <?php
- /*
- * This file is part of the Jiannei/lumen-api-starter.
- *
- * (c) Jiannei <longjian.huang@foxmail.com>
- *
- * This source file is subject to the MIT license that is bundled
- * with this source code in the file LICENSE.
- */
- use Illuminate\Support\Facades\Route;
- use Jiannei\Response\Laravel\Support\Facades\Response;
- /*
- |--------------------------------------------------------------------------
- | Application Routes
- |--------------------------------------------------------------------------
- |
- | Here is where you can register all of the routes for an application.
- | It is a breeze. Simply tell Lumen the URIs it should respond to
- | and give it the Closure to call when that URI is requested.
- |
- */
- Route::get('/', function () {
- if (config('app.debug')) {
- return Response::success([
- 'name' => config('app.name'),
- 'version' => app()->version(),
- ]);
- }
- return 'hello word!';
- });
|