Combine conditionals in logout script