Skip to content

Instantly share code, notes, and snippets.

@akgupta
Last active December 15, 2015 02:09
Show Gist options
  • Select an option

  • Save akgupta/5185300 to your computer and use it in GitHub Desktop.

Select an option

Save akgupta/5185300 to your computer and use it in GitHub Desktop.
var editEnabledOnIPhone = (req.buckets['profile.mobile.edit.iphone'] === 'enabled')
&& isClient(req, 'iphone', '5.0.9', '>=');
// profile edit on android has problems on Android OS versions below 3.0 for client versions < 2.5.4
var editEnabledOnAndroid = ((req.buckets['profile.mobile.edit.android'] === 'enabled') &&
(isClient(req, 'android', '2.5.1', '>=', "3.0", ">=") ||
isClient(req, 'android', '2.5.4', '>='))) ;
var editEnabledOnTouch = (req.buckets['profile.mobile.edit'] === 'enabled') &&
isClient(req, 'touch');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment