Damn unnested if-statements!