I've got a web app in which there are several different user roles (standard users, moderators, admins etc). There are various actions that admins can take that moderators can't; there are actions that moderators can take but standard users can't.
At the moment, the buttons that trigger these actions are rendered on every request to the page, regardless of whether there's a user logged in or whether they can actually use the button or not.
My two options are to do what I'm doing now (render the buttons for every request), or to do some additional checks and only render the buttons if they can actually be used.
The advantage of the latter is that at face value it seems like better UX. However, doing those additional checks will take a not-insignificant chunk of server time, so the page will load noticeably slower.
Which of these two options is better in a UX context?