fixed problem with empty strings