Adding rectangle guard