improve catch errors and comparate application name in lowercase