mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-05 17:50:03 +00:00
Code Modernization: Use instanceof instead of a comparison with get_class().
Includes adjusting external libraries which are no longer maintained externally. Props jrf. See #50767. git-svn-id: https://develop.svn.wordpress.org/trunk@49194 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -276,7 +276,7 @@ class Text_Diff {
|
||||
|
||||
$prevtype = null;
|
||||
foreach ($this->_edits as $edit) {
|
||||
if ($prevtype == get_class($edit)) {
|
||||
if ($edit instanceof $prevtype) {
|
||||
trigger_error("Edit sequence is non-optimal", E_USER_ERROR);
|
||||
}
|
||||
$prevtype = get_class($edit);
|
||||
|
||||
Reference in New Issue
Block a user