CORE-5832: fixed the code to determine whether or not an app is disabled