 modules/mm_antiword/mm_antiword.info    |  2 +-
 modules/mm_antiword/mm_antiword.install |  4 +--
 modules/mm_antiword/mm_antiword.module  | 20 +++++------
 modules/mm_compress/mm_compress.inc     |  6 ++--
 modules/mm_dir/mm_dir.install           |  2 --
 modules/mm_dir/mm_dir.module            |  6 ++--
 modules/mm_ffmpeg/mm_ffmpeg.module      | 62 ++++++++++++++++++++-------------
 7 files changed, 56 insertions(+), 46 deletions(-)

diff --git a/modules/mm_antiword/mm_antiword.info b/modules/mm_antiword/mm_antiword.info
index 5e707a1..2e3952b 100644
--- a/modules/mm_antiword/mm_antiword.info
+++ b/modules/mm_antiword/mm_antiword.info
@@ -3,4 +3,4 @@ description = Support for converting MS documents into other formats
 package = "Media Mover"
 dependencies[] = media_mover_api
 core = 7.x
-configure = admin/config/media/media-mover/settings/mm_antiword
\ No newline at end of file
+configure = admin/config/media/media_mover/settings/mm_antiword
diff --git a/modules/mm_antiword/mm_antiword.install b/modules/mm_antiword/mm_antiword.install
index 640eb35..8b3040c 100644
--- a/modules/mm_antiword/mm_antiword.install
+++ b/modules/mm_antiword/mm_antiword.install
@@ -1,7 +1,5 @@
 <?php
 
-// $Id$
-
 /**
  * @file
  * Install file for mm antiword
@@ -22,7 +20,7 @@ function mm_antiword_uninstall() {
 function mm_antiword_enable() {
   if (! mm_antiword_binary_search()) {
     drupal_set_message(t('Failed to find Antiword binary. Please set the path in your !settings.', array(
-      '!settings' => l(t('settings'), 'admin/build/media_mover/settings/mm_antiword')
+      '!settings' => l(t('settings'), MMA_CONFIG_PATH . '/settings/mm_antiword')
     )), 'error');
   }
 }
diff --git a/modules/mm_antiword/mm_antiword.module b/modules/mm_antiword/mm_antiword.module
index cc61896..96b1c1f 100644
--- a/modules/mm_antiword/mm_antiword.module
+++ b/modules/mm_antiword/mm_antiword.module
@@ -11,7 +11,7 @@
  */
 function mm_antiword_menu() {
   // test page
-  $items['admin/config/media/media-mover/settings/mm-antiword'] = array(
+  $items[MMA_CONFIG_PATH . '/settings/mm_antiword'] = array(
     'title' => 'Antiword',
     'page callback' => 'drupal_get_form',
     'page arguments' => array('mm_antiword_admin_form'),
@@ -50,7 +50,7 @@ function mm_antiword_media_mover() {
  *
  * @return array, drupal form
  */
-function mm_antiword_admin_form() {
+function mm_antiword_admin_form($form, &$form_state) {
   $form = array();
   // Automatically look for the binary
   if (! mm_antiword_binary_check() ) {
@@ -134,12 +134,12 @@ function mm_antiword_convert($step, $file) {
 
   // Create the output file in the tmp directory. Note that this can't be a URI
   // @TODO URI = BAD THINGS HAPPEN HERE
-  $output_file = file_create_filename(basename($file->uri) .'.'. $step->settings['mm_antiword_output_type'], file_directory_temp());
+  $output_file = file_create_filename(basename($file->uri) . '.' . $step->settings['mm_antiword_output_type'], file_directory_temp());
 
   // Build the command
   $command = array(
     $path_to_antiword,
-    '-m '. $step->settings['mm_antiword_output_char_type'],
+    '-m ' . $step->settings['mm_antiword_output_char_type'],
     mm_antiword_output_configuration($step),
     escapeshellarg($local_filepath),
     '>',
@@ -190,13 +190,13 @@ function mm_antiword_convert($step, $file) {
 function mm_antiword_output_configuration($step) {
   switch ($step->settings['mm_antiword_output_type']) {
     case 'pdf':
-      $configuration = '-a '. $step->settings['mm_antiword_page_size'];
-    break;
+      $configuration = '-a ' . $step->settings['mm_antiword_page_size'];
+      break;
     case 'ps':
-      $configuration = '-p '. $step->settings['mm_antiword_page_size'];
-    break;
+      $configuration = '-p ' . $step->settings['mm_antiword_page_size'];
+      break;
     case 'txt':
-    break;
+      break;
   }
   return $configuration;
 }
@@ -212,7 +212,7 @@ function mm_antiword_binary_search() {
     variable_set('mm_antiword_path', $path);
     return TRUE;
   }
-  watchdog('mm_antiword', 'Failed to find binary. Please check your settings.', array(), WATCHDOG_ERROR, l(t('Antiword Settings'), 'admin/build/media_mover/settings/mm_antiword'));
+  watchdog('mm_antiword', 'Failed to find binary. Please check your settings.', array(), WATCHDOG_ERROR, l(t('Antiword Settings'), MMA_CONFIG_PATH . '/settings/mm_antiword'));
   return FALSE;
 }
 
diff --git a/modules/mm_compress/mm_compress.inc b/modules/mm_compress/mm_compress.inc
index d31fedb..e85107e 100644
--- a/modules/mm_compress/mm_compress.inc
+++ b/modules/mm_compress/mm_compress.inc
@@ -10,12 +10,12 @@
  */
 class ArchiverTarMediaMover extends ArchiverTar {
 
-    public function __construct($file_path) {
-      // @TODO check and see if we should compress?
+  public function __construct($file_path) {
+    // @TODO check and see if we should compress?
     $this->tar = new Archive_Tar($file_path, true);
   }
 
- /**
+  /**
    * Implement the add function with the ability to not use the full filepath
    *
    * In this case $basename can only be true or false. If it is set the full
diff --git a/modules/mm_dir/mm_dir.install b/modules/mm_dir/mm_dir.install
index 62ff813..d1f094e 100644
--- a/modules/mm_dir/mm_dir.install
+++ b/modules/mm_dir/mm_dir.install
@@ -1,7 +1,5 @@
 <?php
 
-// $Id$
-
 /**
  * @file
  * Installation for mm dir
diff --git a/modules/mm_dir/mm_dir.module b/modules/mm_dir/mm_dir.module
index d3ee94f..4a7813a 100644
--- a/modules/mm_dir/mm_dir.module
+++ b/modules/mm_dir/mm_dir.module
@@ -12,7 +12,7 @@
 
 
 /**
- * Implementation of hook_media_mover().
+ * Implements hook_media_mover().
  *
  * @return array
  */
@@ -82,7 +82,7 @@ function mm_dir_select_config_validate($element, &$form_state) {
   // Is the path valid?
   if (! is_dir($element['path']['#value'])) {
     if (! drupal_mkdir($element['path']['#value'], NULL, TRUE)) {
-      form_set_error(implode('][',$element['path']['#parents']), t('Sorry, either the source directory does not exist and/or the webserver does not have sufficient permissions to create it.'));
+      form_set_error(implode('][', $element['path']['#parents']), t('Sorry, either the source directory does not exist and/or the webserver does not have sufficient permissions to create it.'));
     }
   }
 }
@@ -139,7 +139,7 @@ function mm_dir_store_config_validate($element, &$form_state) {
   }
   // Is destination valid?
   if (! file_prepare_directory($element['path']['#value'], FILE_CREATE_DIRECTORY) ) {
-    form_set_error(implode('][',$element['path']['#parents']), t('Sorry, either
+    form_set_error(implode('][', $element['path']['#parents']), t('Sorry, either
       the target directory can not be created or the webserver does not have
       sufficient permissions to create it.'));
   }
diff --git a/modules/mm_ffmpeg/mm_ffmpeg.module b/modules/mm_ffmpeg/mm_ffmpeg.module
index 4126762..d6998c8 100644
--- a/modules/mm_ffmpeg/mm_ffmpeg.module
+++ b/modules/mm_ffmpeg/mm_ffmpeg.module
@@ -5,7 +5,7 @@
 /**
  * @file
  * Provides integration with ffmpeg_wrapper module
- * @ TODO lots of configuration fixes which need to be tied to ffmpeg_wrapper
+ * @TODO lots of configuration fixes which need to be tied to ffmpeg_wrapper
  */
 
 /* ************************************************ */
@@ -13,23 +13,33 @@
 /* ************************************************ */
 
 /**
- * Implementation of hook_help().
+ * Implements hook_help().
  */
 function mm_ffmpeg_help($path, $arg) {
   switch ($path) {
-    case 'admin/modules#description' :
+    case 'admin/modules#description':
       return t('Helper module for Media Mover. Allows users to convert video and image files');
   }
   return;
 }
 
+/**
+ * Implements hook_theme().
+ */
+function mm_ffmpeg_theme() {
+  return array(
+    'mm_ffmpeg_email_user_error' => array(
+      'variables' => array('account' => NULL, 'file' => NULL),
+    ),
+  );
+}
 
 /* ************************************************ */
 /* Contrib hook functions                           */
 /* ************************************************ */
 
 /**
- * Implementation of hook_media_mover().
+ * Implements hook_media_mover().
  *
  * @return array
  */
@@ -72,7 +82,7 @@ function mm_ffmpeg_video_convert_config($step) {
  * @return $form
  */
 function mm_ffmpeg_thumbnails_config($step) {
-  drupal_add_js(drupal_get_path('module', 'ffmpeg_wrapper_ui') .'/ffmpeg_wrapper_ui.js');
+  drupal_add_js(drupal_get_path('module', 'ffmpeg_wrapper_ui') . '/ffmpeg_wrapper_ui.js');
   $frame_sizes = ffmpeg_wrapper_ui_frame_sizes();
   $frame_sizes['other'] = t('Other');
   $form['mm_thumbnails'] = array(
@@ -103,7 +113,7 @@ function mm_ffmpeg_thumbnails_config($step) {
   $form['mm_thumbnails']['thumbnailer_time'] = array(
     '#type' => 'textfield',
     '#title' => t('Thumbnail time'),
-    '#default_value' => ! empty($step->settings['thumbnailer_time']) ? $step->settings['thumbnailer_time'] : '00:00:02' ,
+    '#default_value' => ! empty($step->settings['thumbnailer_time']) ? $step->settings['thumbnailer_time'] : '00:00:02',
     '#description' => t('Take the first/only thumbnail screen shot from this time, in the form <em>00:00:02</em>.'),
   );
   $form['mm_thumbnails']['multiple'] = array(
@@ -119,7 +129,7 @@ function mm_ffmpeg_thumbnails_config($step) {
     '#type' => 'select',
     '#title' => t('Generate thumbnails'),
     '#options' => $options,
-    '#default_value' => ! empty($step->settings['thumbnailer_type']) ? $step->settings['thumbnailer_type'] : 'number' ,
+    '#default_value' => ! empty($step->settings['thumbnailer_type']) ? $step->settings['thumbnailer_type'] : 'number',
     '#description' => t('Set the type of thumbnailing you wish to do. Choosing "Specify quantity" will generate a thumbnail every duration/X seconds for a total of X thumbnails. Choosing "Specify interval" will create a thumbnail every X number of seconds through the duration of the video.'),
   );
   $options = drupal_map_assoc(array(1, 5, 10, 15, 20, 30, 45, 60));
@@ -173,10 +183,10 @@ function mm_ffmpeg_video_convert($step, &$file) {
     $message = 'FFmpeg can not decode this file: %file !link';
     $variables = array(
       '%file' => $file->uri,
-      '!link' => l(t('media mover file'), 'admin/build/media_mover/file/edit/' . $file->mmfid)
+      '!link' => l(t('media mover file'), MMA_CONFIG_PATH . '/file/edit/' . $file->mmfid)
     );
 
-    $link = l("node " . $file->nid,  "node/" . $file->nid . "/edit");
+    $link = l("node " . $file->nid,   "node/" . $file->nid . "/edit");
     watchdog('mm_ffmpeg', $message, $variables, WATCHDOG_ERROR, $link);
     return FALSE;
   }
@@ -193,7 +203,7 @@ function mm_ffmpeg_video_convert($step, &$file) {
   $ffmpeg = ffmpeg_wrapper_convert_file($params);
 
   if ($ffmpeg->errors) {
-    $message = 'MM FFmpeg converted this file: !file<br />ffmpeg ran this command:<br />  !command' ;
+    $message = 'MM FFmpeg converted this file: !file<br />ffmpeg ran this command:<br />  !command';
     $variables = array(
       '!errors' => implode("\n", $ffmpeg->errors),
       '!command' => $ffmpeg->command
@@ -298,8 +308,8 @@ function mm_ffmpeg_thumbnails($step, $file) {
  * @param unknown_type $size
  */
 function mm_ffmpeg_thumbnail_create($source, $output_file, $time, $size = FALSE) {
-   // get input file
-  $options[] = '-i \''. $source .'\'';
+  // get input file
+  $options[] = '-i \'' . $source . '\'';
   // set frame time and disable audio
   $options[] = '-vframes 1 -ss \'' . $time . '\' -an';
   // set codec
@@ -308,20 +318,20 @@ function mm_ffmpeg_thumbnail_create($source, $output_file, $time, $size = FALSE)
   if ($size) {
     $options[] = '-s \'' . $size . '\'';
   }
-  $options[] = '\'' . $output_file .'\'';
+  $options[] = '\'' . $output_file . '\'';
 
   // Run the full command with no verbosity
   $ffmpeg = ffmpeg_wrapper_run_command(implode(" ", $options), '-1');
 
   if ($ffmpeg->errors) {
-    $message = 'MM FFmpeg converted this file: !file<br />ffmpeg ran this command:<br />  !command' ;
+    $message = 'MM FFmpeg converted this file: !file<br />ffmpeg ran this command:<br />  !command';
     $variables = array(
       '!errors' => implode("\n", $ffmpeg->errors),
       '!command' => $ffmpeg->command,
       '!file' => $source
     );
-    // TODO define $link.
-    watchdog('mm_ffmpeg', $message, $variables, WATCHDOG_ERROR, $link);
+    // @TODO define $link.
+    watchdog('mm_ffmpeg', $message, $variables, WATCHDOG_ERROR /*, $link*/);
     return FALSE;
   }
   return TRUE;
@@ -360,7 +370,7 @@ function mm_ffmpeg_admin() {
     '#description' => t('Comma seperated list of email addresses to notify when an encoding error happens.'),
   );
 
-  // @ TODO this hasn't been supported yet I think
+  // @TODO this hasn't been supported yet I think
   $form['mm_ffmpeg']['errors']['ffmpeg_error_user'] = array(
     '#type' => 'checkbox',
     '#title' => t('Notify uploader'),
@@ -395,10 +405,11 @@ function mm_ffmpeg_thumbnails_config_validate($element, &$form_state) {
   }
   if (empty($values['thumbnailer_size_other'])) {
     if ($values['thumbnailer_size'] == 'other') {
-      form_set_error(implode('][',$element['#parents']) . "][thumbnailer_size_other", t('Sorry, you have chosen "Other" for the thumbnail size but thumbnail size other is empty.  Please enter a thumbnail size.'));
+      form_set_error(implode('][', $element['#parents']) . "][thumbnailer_size_other", t('Sorry, you have chosen "Other" for the thumbnail size but thumbnail size other is empty.  Please enter a thumbnail size.'));
     }
-  } elseif (! preg_match('/^\d+x\d+$/', $values['thumbnailer_size_other'])) {
-    form_set_error(implode('][',$element['#parents']) . "][thumbnailer_size_other", t('The size must be of the format 600x400 (width x height)'));
+  }
+  elseif (! preg_match('/^\d+x\d+$/', $values['thumbnailer_size_other'])) {
+    form_set_error(implode('][', $element['#parents']) . "][thumbnailer_size_other", t('The size must be of the format 600x400 (width x height)'));
   }
 }
 
@@ -412,12 +423,15 @@ function mm_ffmpeg_thumbnails_config_validate($element, &$form_state) {
  * @param $account is a drupal user account
  * @param $file is the media mover file array
  */
-function theme_mm_ffmpeg_email_user_error($account, $file) {
+// @todo theme_mm_ffmpeg_email_user_error seems UNUSED.
+function theme_mm_ffmpeg_email_user_error($variables) {
+  $account = $variables['account'];
+  $file = $variables['file'];
   $file_parts = pathinfo($file['harvest_file']);
-  $file = $file_parts['basename'] .'.'. $file_parts['extension'];
+  $file = $file_parts['basename'] . '.' . $file_parts['extension'];
   $body = t('We\'re sorry, but we\'re having a hard time converting a file you uploaded.') . "\n";
-  $body .= $file ."\n\n";
-  $body .= t('We\'ll take a look at the file and see if we can help, '."\n".'but you can always try converting to a standard format and uploading again.') ."\n\n";
+  $body .= $file . "\n\n";
+  $body .= t('We\'ll take a look at the file and see if we can help, ' . "\n" . 'but you can always try converting to a standard format and uploading again.') . "\n\n";
   $body .= t('Sorry, and thanks for using our site.');
   return $body;
 }
