Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 3d7f6c6

Browse filesBrowse files
committed
[DomCrawler] Remove the overridden getHash() method to prevent problems when cloning the crawler
Overriding the SplObjectStorage::getHash() is affected by a PHP bug (https://bugs.php.net/bug.php?id=67582), which makes the Crawler unusable in Symfony 2.8 for anyone who relied on SplObjectStorage methods. Removing the getHash() method means we will no longer trigger the deprecation error. Given this method is unlikely to be used directly and other SplObjectStorage methods will trigger the error, it is the simplest thing we can do to maintain BC.
1 parent 3c382c5 commit 3d7f6c6
Copy full SHA for 3d7f6c6

File tree

1 file changed

+0
-10
lines changed
Filter options

1 file changed

+0
-10
lines changed

‎src/Symfony/Component/DomCrawler/Crawler.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/DomCrawler/Crawler.php
-10Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -950,16 +950,6 @@ public function offsetGet($object)
950950
return parent::offsetGet($object);
951951
}
952952

953-
/**
954-
* @deprecated Using the SplObjectStorage API on the Crawler is deprecated as of 2.8 and will be removed in 3.0.
955-
*/
956-
public function getHash($object)
957-
{
958-
$this->triggerDeprecation(__METHOD__, true);
959-
960-
return parent::getHash($object);
961-
}
962-
963953
/**
964954
* Filters the list of nodes with an XPath expression.
965955
*

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.