I am wondering if you ever figured out the problem with the 502 Bad Gateway error. I am currently working on a plugin and am struggling to get it to work with Nginx and PHP-FPM / FastCGI.
It breaks the entire WordPress Site when I use the current_user_can() function. In particular, current_user_can(‘editor’) and current_user_can(‘author’). In version 0.1 of my plugin, I used $current_user->user_level, but WordPress doesn’t recommend doing that so I am trying to make current_user_can(‘editor’) work. Perhaps I will have to approach this differently to figure out whether a user is an Editor/Author…