get first character

Fixed getting first character from string.