Forum Discussion
Thanks for the tip VarunGrazitti but using rest affects my component for regular users and they see 'widget cannot be displayed' for them except for their own avatar. I am all for keeping things as secure as possible but I need the component to work for everyone. Any ideas why that would happen?
jaread83 - I looked into this and following is the issue.
When you are making call as rest in logged out state, there are few nodes missing in registration_data
"registration_data":{ "type":"registration_data", "registration_time":"2014-09-18T13:48:50.554-07:00" }
For a logged in user, the API returns all the nodes as:
"registration_data":{ "type":"registration_data", "registration_time":"2014-09-18T13:48:50.554-07:00", "status":"fully-registered", "registration_access_level":"all", "confirm_email_status":true }
and you are using registration_data.status in your code which is not available when the user is logged out, hence the error:
<#if user.online_status = 'online' & user.registration_data.status = 'fully-registered'>
You could modify the code using if user is logged in or not. You should also use attempt recover blocks.
I hope this helps.
Related Content
- 8 days ago
- 2 years ago
- 11 months ago