File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed
user_guide_src/source/tutorial Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ public function index()
1313 $ data ['news_list ' ] = $ model ->getNews ();
1414 }
1515
16- public function show ($ slug = null )
16+ public function show (? string $ slug = null )
1717 {
1818 $ model = model (NewsModel::class);
1919
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ class News extends BaseController
99{
1010 // ...
1111
12- public function show ($ slug = null )
12+ public function show (? string $ slug = null )
1313 {
1414 $ model = model (NewsModel::class);
1515
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ public function index()
99 return view ('welcome_message ' );
1010 }
1111
12- public function view ($ page = 'home ' )
12+ public function view (string $ page = 'home ' )
1313 {
1414 // ...
1515 }
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ class Pages extends BaseController
88{
99 // ...
1010
11- public function view ($ page = 'home ' )
11+ public function view (string $ page = 'home ' )
1212 {
1313 if (! is_file (APPPATH . 'Views/pages/ ' . $ page . '.php ' )) {
1414 // Whoops, we don't have a page for that!
You can’t perform that action at this time.
0 commit comments