| @@ 2650-2658 (lines=9) @@ | ||
| 2647 | * @param string $url |
|
| 2648 | * @return string |
|
| 2649 | */ |
|
| 2650 | public static function removeProtocolFromUrl($url) { |
|
| 2651 | if (strpos($url, 'https://') === 0) { |
|
| 2652 | return substr($url, strlen('https://')); |
|
| 2653 | } else if (strpos($url, 'http://') === 0) { |
|
| 2654 | return substr($url, strlen('http://')); |
|
| 2655 | } |
|
| 2656 | ||
| 2657 | return $url; |
|
| 2658 | } |
|
| 2659 | ||
| 2660 | /** |
|
| 2661 | * try http post first with https and then with http as a fallback |
|
| @@ 466-474 (lines=9) @@ | ||
| 463 | * @param string $url |
|
| 464 | * @return string |
|
| 465 | */ |
|
| 466 | private function removeProtocolFromUrl($url) { |
|
| 467 | if (strpos($url, 'https://') === 0) { |
|
| 468 | return substr($url, strlen('https://')); |
|
| 469 | } else if (strpos($url, 'http://') === 0) { |
|
| 470 | return substr($url, strlen('http://')); |
|
| 471 | } |
|
| 472 | ||
| 473 | return $url; |
|
| 474 | } |
|
| 475 | ||
| 476 | public function triggerChange($feature, $value = null) { |
|
| 477 | if ($this->emitter && in_array($feature, $this->account->getUpdatedFields())) { |
|