import _ from 'lodash';

const IfPermission = props =>
  (props.stripes.hasPerm(props.perm) ? props.children : null);

export default IfPermission;

@@ -16,16 +16,52 @@
 lodash';
+%0Aimport PropTypes from 'prop-types';
 %0A%0Aconst 
@@ -79,25 +79,47 @@
 n = 
+(
 props
+, context)
  =%3E
+ %7B
 %0A  
-(props
+return (context
 .str
@@ -168,16 +168,138 @@
 : null);
+%0A%7D%0A%0AIfPermission.contextTypes = %7B%0A  stripes: PropTypes.shape(%7B%0A    hasPerm: PropTypes.func.isRequired,%0A  %7D).isRequired,%0A%7D;
 %0A%0Aexport

Use Stripes object from context, not from prop