Fixed potential bug, now checks for startsWith