mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-12-05 20:25:32 +00:00
indexOf is not a safe operation on arrays.
This commit is contained in:
1 parent
ee2f361425
commit
13a5c7f215
1 file changed
+2
-2
@@ -271,7 +271,7 @@ var CPRunLoopLastNativeRunLoop = 0;
|
||||
|
||||
|
||||
// FIXME: Hack for not doing this in CommonJS
|
||||
if (CFBundle.environments().indexOf("Browser") !== -1)
|
||||
if ([CFBundle.environments() indexOfObject:("Browser")] !== CPNotFound)
|
||||
{
|
||||
if (!_runLoopInsuranceTimer)
|
||||
_runLoopInsuranceTimer = window.setNativeTimeout(function()
|
||||
@@ -293,7 +293,7 @@ var CPRunLoopLastNativeRunLoop = 0;
|
||||
_runLoopLock = YES;
|
||||
|
||||
// FIXME: Hack for not doing this in CommonJS
|
||||
if (CFBundle.environments().indexOf("Browser") !== -1)
|
||||
if ([CFBundle.environments() indexOfObject:("Browser")] !== CPNotFound)
|
||||
{
|
||||
if (_runLoopInsuranceTimer)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user