Removed some redundant code from String