Completed
Push — master ( 57cc19...59c015 )
by Aimeos
02:30
created
src/Aimeos/Shop/Base/Locale.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 	 *
39 39
 	 * @param \Illuminate\Contracts\Config\Repository $config Configuration object
40 40
 	 */
41
-	public function __construct( \Illuminate\Contracts\Config\Repository $config )
41
+	public function __construct(\Illuminate\Contracts\Config\Repository $config)
42 42
 	{
43 43
 		$this->config = $config;
44 44
 	}
@@ -50,25 +50,25 @@  discard block
 block discarded – undo
50 50
 	 * @param \Aimeos\MShop\Context\Item\Iface $context Context object
51 51
 	 * @return \Aimeos\MShop\Locale\Item\Iface Locale item object
52 52
 	 */
53
-	public function get( \Aimeos\MShop\Context\Item\Iface $context )
53
+	public function get(\Aimeos\MShop\Context\Item\Iface $context)
54 54
 	{
55
-		if( $this->locale === null )
55
+		if ($this->locale === null)
56 56
 		{
57
-			$site = Input::get( 'site', 'default' );
58
-			$currency = Input::get( 'currency', '' );
59
-			$lang = Input::get( 'locale', '' );
57
+			$site = Input::get('site', 'default');
58
+			$currency = Input::get('currency', '');
59
+			$lang = Input::get('locale', '');
60 60
 
61
-			if( Route::current() )
61
+			if (Route::current())
62 62
 			{
63
-				$site =  Route::input( 'site', $site );
64
-				$currency = Route::input( 'currency', $currency );
65
-				$lang = Route::input( 'locale', $lang );
63
+				$site = Route::input('site', $site);
64
+				$currency = Route::input('currency', $currency);
65
+				$lang = Route::input('locale', $lang);
66 66
 			}
67 67
 
68
-			$disableSites = $this->config->get( 'shop.disableSites', true );
68
+			$disableSites = $this->config->get('shop.disableSites', true);
69 69
 
70
-			$localeManager = \Aimeos\MShop\Locale\Manager\Factory::createManager( $context );
71
-			$this->locale = $localeManager->bootstrap( $site, $lang, $currency, $disableSites );
70
+			$localeManager = \Aimeos\MShop\Locale\Manager\Factory::createManager($context);
71
+			$this->locale = $localeManager->bootstrap($site, $lang, $currency, $disableSites);
72 72
 		}
73 73
 
74 74
 		return $this->locale;
@@ -82,13 +82,13 @@  discard block
 block discarded – undo
82 82
 	 * @param string $site Unique site code
83 83
 	 * @return \Aimeos\MShop\Locale\Item\Iface Locale item object
84 84
 	 */
85
-	public function getBackend( \Aimeos\MShop\Context\Item\Iface $context, $site )
85
+	public function getBackend(\Aimeos\MShop\Context\Item\Iface $context, $site)
86 86
 	{
87
-		$localeManager = \Aimeos\MShop\Factory::createManager( $context, 'locale' );
87
+		$localeManager = \Aimeos\MShop\Factory::createManager($context, 'locale');
88 88
 
89 89
 		try {
90
-			$localeItem = $localeManager->bootstrap( $site, '', '', false, null, true );
91
-		} catch( \Aimeos\MShop\Exception $e ) {
90
+			$localeItem = $localeManager->bootstrap($site, '', '', false, null, true);
91
+		} catch (\Aimeos\MShop\Exception $e) {
92 92
 			$localeItem = $localeManager->createItem();
93 93
 		}
94 94
 
Please login to merge, or discard this patch.