Hi,
I have an issue with Loop switch which used to work before.
Video explainer: Screen Recording 1-12-2023 at 15.31.webm
The Switch and When rule is only being applied when current user is Admin. I am not sure why or when this started to happen.
template:
<Set local=bp_fn_user><Route part=2 /></Set>
<If loop exists type=forestmessages custom_field=fm_forest_id custom_field_value="{Get local=bp_fn_user}" orderby=date order=desc paged=5>
<Loop>
<div class="forestmessages-img">
<Field acf_image=fm_planter_image width="50" height="50"/></div>
<div class="forestmessages">
<div class="fm_small">
<Switch field="author_id">
<When value="4454" />
<Field acf_editor=field_5dd01c52cd659 /> <Field acf_editor=field_5dd01c6224c8c /> - <Field publish_date date_format="d.m.Y" />
<When />
<a href="https://forestnation.com/net/forests/{Field author_user_nicename}"><Field author_full_name /></a> - <Field publish_date date_format="d.m.Y" /><br>
</Switch>
</div>
<div class="forestmessages-content"><p><Field content /></p></div>
<div class="fm_amount"><span><Field acf_editor=fm_trees_planted /> Trees<br>
</span></div></div>
</Loop>
<Else />
<div class="forestmessages-img">
<img src="https://forestnation.com/net/wp-content/uploads/sites/7/2020/02/morio-green-100.png"></div>
<div class="forestmessages">
<div class="forestmessages-content">Be the first to plant for M.E!</div>
</div>
</If>
<div class="forestmessages-pagination">
<PaginateButtons /></div>