modified bracket handling