Skip to content

Commit 8e91f61

Browse files
committed
Fix missing isLocal method
1 parent b2f65f2 commit 8e91f61

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

src/Application.php

+21-1
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,26 @@ public function environment()
207207
return $env;
208208
}
209209

210+
/**
211+
* Determine if the application is in the local environment.
212+
*
213+
* @return bool
214+
*/
215+
public function isLocal()
216+
{
217+
return $this->environment() === 'local';
218+
}
219+
220+
/**
221+
* Determine if the application is in the production environment.
222+
*
223+
* @return bool
224+
*/
225+
public function isProduction()
226+
{
227+
return $this->environment() === 'production';
228+
}
229+
210230
/**
211231
* Determine if the given service provider is loaded.
212232
*
@@ -913,7 +933,7 @@ public function runningInConsole()
913933
*/
914934
public function runningUnitTests()
915935
{
916-
return $this->environment() == 'testing';
936+
return $this->environment() === 'testing';
917937
}
918938

919939
/**

0 commit comments

Comments
 (0)