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
b3b5e36d
Commit
b3b5e36d
authored
Oct 18, 2013
by
resurtm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove use ($this). Related to
9e1b498f
.
parent
9e1b498f
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
ErrorHandler.php
framework/yii/base/ErrorHandler.php
+1
-1
Connection.php
framework/yii/db/Connection.php
+1
-1
Module.php
framework/yii/debug/Module.php
+1
-1
BaseListView.php
framework/yii/widgets/BaseListView.php
+1
-1
No files found.
framework/yii/base/ErrorHandler.php
View file @
b3b5e36d
...
@@ -175,7 +175,7 @@ class ErrorHandler extends Component
...
@@ -175,7 +175,7 @@ class ErrorHandler extends Component
$html
=
rtrim
(
$html
,
'\\'
);
$html
=
rtrim
(
$html
,
'\\'
);
}
elseif
(
strpos
(
$code
,
'()'
)
!==
false
)
{
}
elseif
(
strpos
(
$code
,
'()'
)
!==
false
)
{
// method/function call
// method/function call
$html
=
preg_replace_callback
(
'/^(.*)\(\)$/'
,
function
(
$matches
)
use
(
$this
)
{
$html
=
preg_replace_callback
(
'/^(.*)\(\)$/'
,
function
(
$matches
)
{
return
'<a href="http://yiiframework.com/doc/api/2.0/'
.
$this
->
htmlEncode
(
$matches
[
1
])
.
'" target="_blank">'
.
return
'<a href="http://yiiframework.com/doc/api/2.0/'
.
$this
->
htmlEncode
(
$matches
[
1
])
.
'" target="_blank">'
.
$this
->
htmlEncode
(
$matches
[
1
])
.
'</a>()'
;
$this
->
htmlEncode
(
$matches
[
1
])
.
'</a>()'
;
},
$code
);
},
$code
);
...
...
framework/yii/db/Connection.php
View file @
b3b5e36d
...
@@ -509,7 +509,7 @@ class Connection extends Component
...
@@ -509,7 +509,7 @@ class Connection extends Component
public
function
quoteSql
(
$sql
)
public
function
quoteSql
(
$sql
)
{
{
return
preg_replace_callback
(
'/(\\{\\{(%?[\w\-\. ]+%?)\\}\\}|\\[\\[([\w\-\. ]+)\\]\\])/'
,
return
preg_replace_callback
(
'/(\\{\\{(%?[\w\-\. ]+%?)\\}\\}|\\[\\[([\w\-\. ]+)\\]\\])/'
,
function
(
$matches
)
use
(
$this
)
{
function
(
$matches
)
{
if
(
isset
(
$matches
[
3
]))
{
if
(
isset
(
$matches
[
3
]))
{
return
$this
->
quoteColumnName
(
$matches
[
3
]);
return
$this
->
quoteColumnName
(
$matches
[
3
]);
}
else
{
}
else
{
...
...
framework/yii/debug/Module.php
View file @
b3b5e36d
...
@@ -57,7 +57,7 @@ class Module extends \yii\base\Module
...
@@ -57,7 +57,7 @@ class Module extends \yii\base\Module
$this
->
dataPath
=
Yii
::
getAlias
(
$this
->
dataPath
);
$this
->
dataPath
=
Yii
::
getAlias
(
$this
->
dataPath
);
$this
->
logTarget
=
Yii
::
$app
->
getLog
()
->
targets
[
'debug'
]
=
new
LogTarget
(
$this
);
$this
->
logTarget
=
Yii
::
$app
->
getLog
()
->
targets
[
'debug'
]
=
new
LogTarget
(
$this
);
// do not initialize view component before application is ready (needed when debug in preload)
// do not initialize view component before application is ready (needed when debug in preload)
Yii
::
$app
->
on
(
Application
::
EVENT_BEFORE_ACTION
,
function
()
use
(
$this
)
{
Yii
::
$app
->
on
(
Application
::
EVENT_BEFORE_ACTION
,
function
()
{
Yii
::
$app
->
getView
()
->
on
(
View
::
EVENT_END_BODY
,
array
(
$this
,
'renderToolbar'
));
Yii
::
$app
->
getView
()
->
on
(
View
::
EVENT_END_BODY
,
array
(
$this
,
'renderToolbar'
));
});
});
...
...
framework/yii/widgets/BaseListView.php
View file @
b3b5e36d
...
@@ -92,7 +92,7 @@ abstract class BaseListView extends Widget
...
@@ -92,7 +92,7 @@ abstract class BaseListView extends Widget
public
function
run
()
public
function
run
()
{
{
if
(
$this
->
dataProvider
->
getCount
()
>
0
||
$this
->
empty
===
false
)
{
if
(
$this
->
dataProvider
->
getCount
()
>
0
||
$this
->
empty
===
false
)
{
$content
=
preg_replace_callback
(
"/
{
\\w+
}
/"
,
function
(
$matches
)
use
(
$this
)
{
$content
=
preg_replace_callback
(
"/
{
\\w+
}
/"
,
function
(
$matches
)
{
$content
=
$this
->
renderSection
(
$matches
[
0
]);
$content
=
$this
->
renderSection
(
$matches
[
0
]);
return
$content
===
false
?
$matches
[
0
]
:
$content
;
return
$content
===
false
?
$matches
[
0
]
:
$content
;
},
$this
->
layout
);
},
$this
->
layout
);
...
...
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