scope and privileged commands added. helper function for plugin commands added