Drupal 7 "undefined function" fatal error; from FTP error One of the guys here deleted a module folder, in error, from drupal 7 site using FTP (I know but it was a mistake).

the Commerce module was deleted. Now can not access the site at all as we are getting a fatal error
Fatal error: Call to undefined function commerce_pricing_attributes_property_info_callback() in /var/www/sites/all/modules/contrib/entity/modules/field.info.inc on line 30

Anyone know how to correct it?
line 30 is
    $callback($info, $entity_type, $field, $instance, $field_type);

The function in question is below  

function entity_metadata_field_entity_property_info() {
  $info = array();
  // Loop over all field instances and add them as property.
  foreach (field_info_fields() as $field_name =&gt; $field) {
    $field += array('bundles' =&gt; array());
    if ($field_type = field_info_field_types($field['type'])) {
      // Add in our default callback as the first one.
      $field_type += array('property_callbacks' =&gt; array());
      array_unshift($field_type['property_callbacks'], 'entity_metadata_field_default_property_callback');

      foreach ($field['bundles'] as $entity_type =&gt; $bundles) {
        foreach ($bundles as $bundle) {
          $instance = field_info_instance($entity_type, $field_name, $bundle);

          if ($instance &amp;&amp; empty($instance['deleted'])) {
            foreach ($field_type['property_callbacks'] as $callback) {
              $callback($info, $entity_type, $field, $instance, $field_type);
            }
          }
        }
      }
    }
  }
  return $info;
If you have a backup this is the time to use it.

If not you should:


Put your Site in maintenance mode from command line: https://drupal.org/node/590468 or by using Drush: drush vset maintenance_mode 1
Replace the deleted module with exactly the same version in exactly the same place.
Run update.php either from drush: drush updb or command line: https://drupal.org/upgrade/running-update-php
All should be fine. 


Please report back if this works or if another solution is found