Laravel: «Class not found» error after renaming

After renaming some Class, we might face some problem related with the cache, so our app is still looking for the old Class instead the renamed one. Here it is explained how to clear the caches and work withthe good ones.

Address to the folder /bootstrap/cache/

$ cd bootstrap/cache/

And clear caches with the following command:

$ rm -rf *.php