renamed webreader loadUrl method to getUrl to represent action by name
-> deprecated old name
This commit is contained in:
		| @@ -22,7 +22,7 @@ abstract class WebReader { | |||||||
| 	 * @param callable $function | 	 * @param callable $function | ||||||
| 	 * @return Response | 	 * @return Response | ||||||
| 	 */ | 	 */ | ||||||
| 	public static function loadUrl($url, callable $function = null) { | 	public static function getUrl($url, callable $function = null) { | ||||||
| 		$request  = static::newRequest($url); | 		$request  = static::newRequest($url); | ||||||
| 		$response = $request->send(); | 		$response = $request->send(); | ||||||
| 		if ($function) { | 		if ($function) { | ||||||
| @@ -31,6 +31,17 @@ abstract class WebReader { | |||||||
| 		return $response; | 		return $response; | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
|  | 	/** | ||||||
|  | 	 * @deprecated | ||||||
|  | 	 * @see WebReader::getUrl() | ||||||
|  | 	 */ | ||||||
|  | 	public static function loadUrl($url, callable $function = null) { | ||||||
|  | 		if ($function) { | ||||||
|  | 			return static::getUrl($url, $function); | ||||||
|  | 		} | ||||||
|  | 		return static::getUrl($url); | ||||||
|  | 	} | ||||||
|  |  | ||||||
| 	/** | 	/** | ||||||
| 	 * Create a new cURL Request for the given URL | 	 * Create a new cURL Request for the given URL | ||||||
| 	 * | 	 * | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user