Warnings handle 

Change on the regex variable such that it distinguish warnings from errors.