atom-autocomplete-php icon indicating copy to clipboard operation
atom-autocomplete-php copied to clipboard

ErrorHandler: Renaming \Exception to \Throwable because PHP 7 throws Errors to

Open vcampitelli opened this issue 6 years ago • 0 comments

At Peekmo\AtomAutocompletePhp\ErrorHandler there's a method called onException that was expecting a \Exception object to display the message and die.

Since PHP 7, errors are thrown too, but as an \Error class. Both \Exception and \Error classes implement a \Throwable interface. To make the code more compliant and avoid Fatal Errors due to an unexpected type received, I'm renaming \Exception to \Throwable in that method.

vcampitelli avatar Mar 21 '19 18:03 vcampitelli