Completed
Pull Request — master (#22)
by Daryl
03:27
created

Geocoder::api_key()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 5
ccs 2
cts 2
cp 1
rs 9.4285
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
namespace Clubdeuce\WPLib\Components\GoogleMaps;
4
5
/**
6
 * Class Geocoder
7
 * @package Clubdeuce\WPLib\Components\GoogleMaps
8
 */
9
class Geocoder extends \Clubdeuce\WPGoogleMaps\Geocoder {
10
11
	/**
12
	 * @param string $address
13
	 *
14
	 * @return \Clubdeuce\WPGoogleMaps\Location|Location|\WP_Error
15
	 */
16
	function geocode( $address ) {
17
18
		$location = parent::geocode( $address );
19
20
		return new Location( array( 'location' => $location ) );
21 1
22
	}
23 1
24
}
25