File tree Expand file tree Collapse file tree 4 files changed +6
-7
lines changed
Expand file tree Collapse file tree 4 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -430,7 +430,7 @@ public function action() {
430430 * @param string $id The id of the element to be created.
431431 * @return RemoteWebElement
432432 */
433- private function newElement ($ id ) {
433+ protected function newElement ($ id ) {
434434 return new RemoteWebElement ($ this ->getExecuteMethod (), $ id );
435435 }
436436
Original file line number Diff line number Diff line change @@ -416,8 +416,7 @@ public function equals(WebDriverElement $other) {
416416 *
417417 * @return RemoteWebElement
418418 */
419- private function newElement ($ id ) {
420- $ class = get_class ($ this );
421- return new $ class ($ this ->executor , $ id );
419+ protected function newElement ($ id ) {
420+ return new static ($ this ->executor , $ id );
422421 }
423422}
Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ public function getWebDriver() {
8585 * @param WebDriverElement $element
8686 * @return EventFiringWebElement
8787 */
88- private function newElement (WebDriverElement $ element ) {
88+ protected function newElement (WebDriverElement $ element ) {
8989 return new EventFiringWebElement ($ element , $ this ->getDispatcher ());
9090 }
9191
Original file line number Diff line number Diff line change @@ -78,8 +78,8 @@ public function getElement() {
7878 * @param WebDriverElement $element
7979 * @return EventFiringWebElement
8080 */
81- private function newElement (WebDriverElement $ element ) {
82- return new EventFiringWebElement ($ element , $ this ->getDispatcher ());
81+ protected function newElement (WebDriverElement $ element ) {
82+ return new static ($ element , $ this ->getDispatcher ());
8383 }
8484
8585 /**
You can’t perform that action at this time.
0 commit comments