1
0
mirror of https://github.com/ascribe/onion.git synced 2024-12-22 17:33:14 +01:00

Fix acl proxy

This commit is contained in:
vrde 2015-07-14 22:50:48 +02:00
parent 63c78d09d9
commit aec1ff2173

View File

@ -28,20 +28,23 @@ let AclProxy = React.createClass({
</span>
);
} else {
if(this.props.aclObject[this.props.aclName]) {
return (
<span>
{this.props.children}
</span>
);
} else {
if(typeof this.props.aclObject[this.props.aclName] === 'undefined') {
console.warn('The aclName you\'re filtering for was not present (undefined) in the aclObject.');
if(this.props.aclObject) {
if(this.props.aclObject[this.props.aclName]) {
return (
<span>
{this.props.children}
</span>
);
} else {
if(typeof this.props.aclObject[this.props.aclName] === 'undefined') {
console.warn('The aclName you\'re filtering for was not present (undefined) in the aclObject.');
}
return null;
}
return null;
}
}
return null;
}
});
export default AclProxy;
export default AclProxy;