fix bug that fails to identify capital characters in functions