fix variable name to make sense to context of function
check if string being parsed before checking anything else, so that it supercedes other parsing