Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
ce12ddb6
Commit
ce12ddb6
authored
May 17, 2014
by
Qiang Xue
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3499 from ShNURoK42/master
Rename errorHandler to getErrorHandler()
parents
aedac962
a07b4afe
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
Controller.php
framework/web/Controller.php
+1
-1
ErrorAction.php
framework/web/ErrorAction.php
+1
-1
No files found.
framework/web/Controller.php
View file @
ce12ddb6
...
@@ -105,7 +105,7 @@ class Controller extends \yii\base\Controller
...
@@ -105,7 +105,7 @@ class Controller extends \yii\base\Controller
public
function
beforeAction
(
$action
)
public
function
beforeAction
(
$action
)
{
{
if
(
parent
::
beforeAction
(
$action
))
{
if
(
parent
::
beforeAction
(
$action
))
{
if
(
$this
->
enableCsrfValidation
&&
Yii
::
$app
->
errorHandler
->
exception
===
null
&&
!
Yii
::
$app
->
getRequest
()
->
validateCsrfToken
())
{
if
(
$this
->
enableCsrfValidation
&&
Yii
::
$app
->
getErrorHandler
()
->
exception
===
null
&&
!
Yii
::
$app
->
getRequest
()
->
validateCsrfToken
())
{
throw
new
BadRequestHttpException
(
Yii
::
t
(
'yii'
,
'Unable to verify your data submission.'
));
throw
new
BadRequestHttpException
(
Yii
::
t
(
'yii'
,
'Unable to verify your data submission.'
));
}
}
return
true
;
return
true
;
...
...
framework/web/ErrorAction.php
View file @
ce12ddb6
...
@@ -68,7 +68,7 @@ class ErrorAction extends Action
...
@@ -68,7 +68,7 @@ class ErrorAction extends Action
public
function
run
()
public
function
run
()
{
{
if
((
$exception
=
Yii
::
$app
->
errorHandler
->
exception
)
===
null
)
{
if
((
$exception
=
Yii
::
$app
->
getErrorHandler
()
->
exception
)
===
null
)
{
return
''
;
return
''
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment