Browse Source

Fix 'requestAnimationFrame is not defined'

Thibaut Courouble 9 years ago
parent
commit
012420c925
1 changed files with 1 additions and 1 deletions
  1. 1 1
      assets/javascripts/lib/util.coffee

+ 1 - 1
assets/javascripts/lib/util.coffee

@@ -279,7 +279,7 @@ $.classify = (string) ->
   string.join('')
 
 $.framify = (fn, obj) ->
-  if requestAnimationFrame
+  if window.requestAnimationFrame
     (args...) -> requestAnimationFrame(fn.bind(obj, args...))
   else
     fn