Solving problem of finding all apps in the server - variable @apps wasn't instantiated