Fixed if-bracket issue