To solve this on index.php add at the bottom
This is fine for fixing on local but if you're doing this on local but if you need to do it on a server a much better solution is to use the module https://www.drupal.org/project/registry_rebuild
Just as a foot note I also got this message
$ drush registry-rebuild
Fatal error: Call to undefined function video_embed_field_property_info_callback() in */profiles/commons/modules/contrib/entity/modules/field.info.inc on line 30
To fix this I had to install the Video Embed Field Module and enable from drush.