fixing bugs in transformation of substring into NSMakeRange