diff --git a/tac_lite.install b/tac_lite.install
index c7c9e4d..a48ccad 100644
--- a/tac_lite.install
+++ b/tac_lite.install
@@ -2,12 +2,12 @@
 
 /**
  * @file
- *   Installation functions for tac_lite.
- *   TODO: All updates need proper error handling and responses
+ * Installation functions for tac_lite.
+ * TODO: All updates need proper error handling and responses
  */
 
 /**
- * Implementation of hook_install().
+ * Implements hook_install().
  *
  * Ensure that tac_lite hooks are invoked after taxonomy module hooks.
  */
@@ -52,16 +52,19 @@ function tac_lite_update_1() {
 }
 
 /**
- * Ensure that the node_access table is thoroughly cleaned up in Drupal 5 update.
+ * Ensure that the node_access table is cleaned up in Drupal 5 update.
  */
 function tac_lite_update_2() {
-  node_access_rebuild(); // Would batch mode help here?
+  // Would batch mode help here?
+  node_access_rebuild();
   // Assume success and return with message.
   return t('Rebuilt node access table for tac_lite module.');
 }
 
 /**
- * Introducing schemes. Rename tac_lite_default_grants to tac_lite_grants_scheme_1.
+ * Introducing schemes.
+ *
+ * Rename tac_lite_default_grants to tac_lite_grants_scheme_1.
  */
 function tac_lite_update_3() {
   $num_updated = db_update('variable')
@@ -78,15 +81,14 @@ function tac_lite_update_3() {
  */
 
 /**
- * Rename permission from "administer_tac_lite" to "administer
- * tac_lite" for UI consistency.
+ * Rename permission from "administer_tac_lite" to "administer tac_lite".
  */
 function tac_lite_update_6001() {
-  // TODO: Please review to make sure this is handling this update properly for this version of code. (only change was formatting and table name)
+  // TODO: Please review to make sure this is handling this update properly for
+  // this version of code. (only change was formatting and table name).
   $result = db_query("SELECT * FROM {role_permission} WHERE perm LIKE '%administer_tac_lite%'");
   foreach ($result as $permission) {
     $perm = str_replace('administer_tac_lite', 'administer tac_lite', $permission->perm);
-    //db_query("UPDATE {permission} SET perm = '". db_escape_string($perm) ."' WHERE rid =". $permission->rid);
     $num_updated = db_update('permission')
     ->fields(array(
       'perm' => $perm,
diff --git a/tac_lite.module b/tac_lite.module
index c825c6f..d008c53 100644
--- a/tac_lite.module
+++ b/tac_lite.module
@@ -1,24 +1,22 @@
 <?php
 /**
  * @file
- *   Control access to site content based on taxonomy, roles and users.
- *
- *
+ * Control access to site content based on taxonomy, roles and users.
  */
 
 /**
- * Implementation of hook_help().
+ * Implements hook_help().
  */
 function tac_lite_help($section) {
   switch ($section) {
     case 'admin/help#tac_lite':
       // $output .= '<p>' . t('') . '</p>';
       $output = '<p>' . t('Taxonomy Access Control Lite allows you to restrict access to site content. It uses a simple scheme based on Taxonomy, Users and Roles.') . '</p>';
-      $output .= '<p>' . t('This module leverages Drupal\'s node_access table allows this module to grant permission to view, update, and delete nodes.  To control which users can <em>create</em> new nodes, use Drupal\'s role based permissions.') . '</p>';
-      $output .= '<p>' . t('It is important to understand that this module <em>grants</em> privileges, as opposed to <em>revoking</em> privileges.  So, use Drupal\'s built-in permissions to hide content from certain roles, then use this module to show the content.  This module cannot hide content that the user is allowed to see based on their existing privileges.') . '</p>';
-$output .= '<p>' . t('There are several steps required to set up Taxonomy Access Control Lite.') . '</p>';
+      $output .= '<p>' . t("This module leverages Drupal's node_access table allows this module to grant permission to view, update, and delete nodes.  To control which users can <em>create</em> new nodes, use Drupal's role based permissions.") . '</p>';
+      $output .= '<p>' . t("It is important to understand that this module <em>grants</em> privileges, as opposed to <em>revoking</em> privileges.  So, use Drupal's built-in permissions to hide content from certain roles, then use this module to show the content.  This module cannot hide content that the user is allowed to see based on their existing privileges.") . '</p>';
+      $output .= '<p>' . t('There are several steps required to set up Taxonomy Access Control Lite.') . '</p>';
       $output .= '<ol>';
-      $output .= '<li>' . t('Define one or more vocabularies whose terms will control which users have access. For example, you could define a vocabulary called \'Privacy\' with terms \'Public\' and \'Private\'.') . '</li>';
+      $output .= '<li>' . t("Define one or more vocabularies whose terms will control which users have access. For example, you could define a vocabulary called 'Privacy' with terms 'Public' and 'Private'.") . '</li>';
       $output .= '<li>' . t('Tell this module which vocabularies control privacy. (!link)', array('!link' => l(t('administer -> people -> access control by taxonomy'), 'admin/people/access/tac_lite'))) . '</li>';
       $output .= '<li>' . t('Configure one or more <em>schemes</em>.   simple site may need only one scheme which grants view permission.  A more complex site might require additional schemes for update and delete.  Each scheme associates roles and terms.  Users will be granted priviliges based on their role and the terms with which nodes are tagged.') . '</li>';
       $output .= '<li>' . t('When settings are correct, <a href=!url>rebuild node_access permissions</a>.', array(
@@ -29,29 +27,30 @@ $output .= '<p>' . t('There are several steps required to set up Taxonomy Access
       $output .= '<p>' . t('Troubleshooting:.') . '<ul>';
       $output .= '<li>' . t('Try rebuilding node_access permissions.') . '</li>';
       $output .= '<li>' . t('Try disabling tac_lite.module, rebuilding permissions.  With the module disabled, users should not have the privileges you are attempting to grant with this module.') . '</li>';
-      $output .= '<li>' . t('The devel_node_access.module (part of <a href=!url>devel</a>) helps to see exactly what Drupal\'s node_access table is doing.', array(
+      $output .= '<li>' . t("The devel_node_access.module (part of <a href=!url>devel</a>) helps to see exactly what Drupal's node_access table is doing.", array(
                    '!url' => 'http://drupal.org/project/devel',
                  )) . '</li>';
       $output .= '</ul></p>';
       return $output;
-      break;
+    break;
+
   }
 }
 
 /**
- * Implementation of hook_perm().
+ * Implements hook_permission().
  */
 function tac_lite_permission() {
   return array(
     'administer tac_lite' => array(
       'title' => t('administer tac_lite'),
-      'description' => t('TODO Add a description for \'administer tac_lite\''),
+      'description' => t("TODO Add a description for 'administer tac_lite'"),
     ),
   );
 }
 
 /**
- * Implementation of hook_menu().
+ * Implements hook_menu().
  */
 function tac_lite_menu() {
   global $user;
@@ -62,7 +61,8 @@ function tac_lite_menu() {
     'description' => "taxonomy-based permissions by tac_lite",
     'page callback' => 'drupal_get_form',
     'page arguments' => array('tac_lite_admin_settings'),
-    'weight' => 1, // after 'roles' tab
+    // After 'roles' tab.
+    'weight' => 1,
     'access arguments' => array('administer tac_lite'),
   );
 
@@ -75,16 +75,17 @@ function tac_lite_menu() {
 
   $schemes = variable_get('tac_lite_schemes', 1);
   for ($i = 1; $i <= $schemes; $i++) {
-    $scheme = variable_get('tac_lite_config_scheme_'. $i, FALSE);
+    $scheme = variable_get('tac_lite_config_scheme_' . $i, FALSE);
     if ($scheme) {
       $title = $scheme['name'];
-    } else {
+    }
+    else {
       $title = "Scheme $i";
     }
     $items['admin/config/people/tac_lite/scheme_' . $i] = array(
       'title' => $title,
       'page callback' => 'tac_lite_admin_settings_scheme',
-      'page arguments' => array((string)$i),
+      'page arguments' => array((string) $i),
       'type' => MENU_LOCAL_TASK,
       'weight' => $i,
       'access arguments' => array('administer tac_lite'),
@@ -95,7 +96,7 @@ function tac_lite_menu() {
 }
 
 /**
- * Returns the settings form
+ * Returns the settings form.
  */
 function tac_lite_admin_settings($form, &$form_state) {
   $vocabularies = taxonomy_get_vocabularies();
@@ -127,8 +128,10 @@ function tac_lite_admin_settings($form, &$form_state) {
     $scheme_options = array();
     // Currently only view, edit, delete permissions possible, so 7
     // permutations will be more than enough.
-    for ($i = 1; $i < 8; $i++)
+    for ($i = 1; $i < 8; $i++) {
       $scheme_options[$i] = $i;
+    }
+
     $form['tac_lite_schemes'] = array(
       '#type' => 'select',
       '#title' => t('Number of Schemes'),
@@ -141,7 +144,8 @@ function tac_lite_admin_settings($form, &$form_state) {
     $form['tac_lite_rebuild'] = array(
       '#type' => 'checkbox',
       '#title' => t('Rebuild content permissions now'),
-      '#default_value' => FALSE, // default false because usually only needed after scheme has been changed.
+      // Default false because usually only needed after changes to the scheme.
+      '#default_value' => FALSE,
       '#description' => t('Do this once, after you have fully configured access by taxonomy.'),
       '#weight' => 9,
     );
@@ -155,8 +159,10 @@ function tac_lite_admin_settings($form, &$form_state) {
 }
 
 /**
- * This form submit callback ensures that the form values are saved, and also
- * the node access database table is rebuilt.
+ * This form submit callback for admin settings.
+ *
+ * Ensures that the form values are saved, and also the node access database
+ * table is rebuilt.
  * 2008 : Modified by Paulo to be compliant with drupal 6
  */
 function _tac_lite_admin_settings_submit($form, &$form_state) {
@@ -175,23 +181,26 @@ function _tac_lite_admin_settings_submit($form, &$form_state) {
   // And rebuild menus, in case the number of schemes has changed.
   menu_rebuild();
 
-  variable_del('tac_lite_rebuild'); // We don't need to store this as a system variable.
+  // We don't need to store this as a system variable.
+  variable_del('tac_lite_rebuild');
 }
 
 /**
  * Menu callback to create a form for each scheme.
- * @param $i
- *   The index of the scheme that we will be creating a form for. Passed in as a page argument from the menu.
+ *
+ * @param int $i
+ *   The index of the scheme that we will be creating a form for. Passed in as a
+ *   page argument from the menu.
  */
 function tac_lite_admin_settings_scheme($i) {
   return drupal_get_form('tac_lite_admin_scheme_form', $i);
 }
 
 /**
- * helper function
+ * Helper function.
  */
 function _tac_lite_config($scheme) {
-  // different defaults for scheme 1
+  // Different defaults for scheme 1.
   if ($scheme === 1) {
     $config = variable_get('tac_lite_config_scheme_' . $scheme, array(
                 'name' => t('read'),
@@ -235,7 +244,7 @@ function tac_lite_admin_scheme_form($form, $form_state, $i) {
     $form['tac_lite_config_scheme_' . $i]['name'] = array(
       '#type' => 'textfield',
       '#title' => t('Scheme name'),
-      '#description' => t('A human-readable name for administrators to see. For example, \'read\' or \'read and write\'.'),
+      '#description' => t("A human-readable name for administrators to see. For example, 'read' or 'read and write'."),
       '#default_value' => $config['name'],
       '#required' => TRUE,
     );
@@ -288,7 +297,7 @@ function tac_lite_admin_scheme_form($form, $form_state, $i) {
 
       $defaults = isset($all_defaults[$rid]) ? $all_defaults[$rid] : NULL;
       foreach ($vids as $vid) {
-        // Build a taxonomy select form element for this vocab
+        // Build a taxonomy select form element for this vocab.
         $v = $vocabularies[$vid];
         $tree = taxonomy_get_tree($v->vid);
         $options = array(0 => '<' . t('none') . '>');
@@ -307,7 +316,8 @@ function tac_lite_admin_scheme_form($form, $form_state, $i) {
     $form['tac_lite_rebuild'] = array(
       '#type' => 'checkbox',
       '#title' => t('Rebuild content permissions now'),
-      '#default_value' => FALSE, // default false because usually only needed after scheme has been changed.
+      // Default false because usually only needed after the scheme changes.
+      '#default_value' => FALSE,
       '#description' => t('Do this once, after you have fully configured access by taxonomy.'),
       '#weight' => 9,
     );
@@ -339,13 +349,15 @@ function tac_lite_admin_scheme_form_submit($form, &$form_state) {
                            '!url' => url('admin/reports/status/rebuild'),
                          )), 'warning');
   }
-  variable_del('tac_lite_rebuild'); // We don't need to store this as a system variable.
+  // We don't need to store this as a system variable.
+  variable_del('tac_lite_rebuild');
 }
 
 /**
- * Implementation of hook_user_categories
+ * Implements hook_user_categories().
  *
- * Creates the user edit category form for tac_lite's user-specific permissions under user/edit
+ * Creates the user edit category form for tac_lite's user-specific permissions
+ * under user/edit
  */
 function tac_lite_user_categories() {
   return array(
@@ -360,17 +372,9 @@ function tac_lite_user_categories() {
 }
 
 /**
- * Implementation of hook_form_alter().
- *
- * @param $form
- *   Nested array of form elements that comprise the form.
- * @param $form_state
- *   A keyed array containing the current state of the form. The arguments that drupal_get_form() was originally called with are available in the array $form_state['build_info']['args'].
- * @param $form_id
- *   String representing the name of the form itself. Typically this is the name of the function that generated the form.
- *
+ * Implements hook_form_alter().
  */
-function tac_lite_form_alter(&$form, &$form_state, $form_id){
+function tac_lite_form_alter(&$form, &$form_state, $form_id) {
   // Catch for the tac_lite category on the user edit form.
   if ($form_id == 'user_profile_form') {
     if ($form['#user_category'] == 'tac_lite') {
@@ -390,20 +394,20 @@ function tac_lite_form_alter(&$form, &$form_state, $form_id){
               '#description' => t('This scheme controls %perms.', array('%perms' => implode(' and ', $perms))),
               '#tree' => TRUE,
             );
-            // Create a form element for each vocabulary
+            // Create a form element for each vocabulary.
             foreach ($vids as $vid) {
               $v = $vocabularies[$vid];
-              // TODO: Should we be looking in form_state also for the default value?
-              // (Might only be necessary if we are adding in custom validation?)
+              // TODO: Should we be looking in form_state also for the default
+              // value? (Might only be necessary if we add custom validation?)
               $default_values = array();
               if (!empty($form['#user']->data[$config['realm']])) {
                 if (isset($form['#user']->data[$config['realm']][$vid])) {
                   $default_values = $form['#user']->data[$config['realm']][$vid];
                 }
               }
-              $form['tac_lite'][$config['realm']][$vid] =  _tac_lite_term_select($v, $default_values);
-              $form['tac_lite'][$config['realm']][$vid]['#description'] =
-                t('Grant permission to this user by selecting terms.  Note that permissions are in addition to those granted based on user roles.');
+              $form['tac_lite'][$config['realm']][$vid] = _tac_lite_term_select($v, $default_values);
+              $form['tac_lite'][$config['realm']][$vid]['#description']
+                = t('Grant permission to this user by selecting terms.  Note that permissions are in addition to those granted based on user roles.');
             }
           }
         }
@@ -415,7 +419,8 @@ function tac_lite_form_alter(&$form, &$form_state, $form_id){
         );
       }
       else {
-        // TODO: Do we need to handle the situation where no vocabularies have been set up yet / none have been assigned to tac_lite?
+        // TODO: Do we need to handle the situation where no vocabularies have
+        // been set up yet / none have been assigned to tac_lite?
       }
       return $form;
     }
@@ -423,20 +428,14 @@ function tac_lite_form_alter(&$form, &$form_state, $form_id){
 }
 
 /**
- * Implementation of hook_user_presave().
+ * Implements hook_user_presave().
  *
- * Move the tac_lite data into the data object
- * @param $edit
- *   The array of form values submitted by the user.
- * @param $account
- *   The user object on which the operation is performed.
- * @param $category
- *   The active category of user information being edited.
+ * Move the tac_lite data into the data object.
  */
 function tac_lite_user_presave(&$edit, $account, $category) {
   // Only proceed if we are in the tac_lite category.
-  if ($category == 'tac_lite'){
-    // Go through each scheme and copy the form value into the data element
+  if ($category == 'tac_lite') {
+    // Go through each scheme and copy the form value into the data element.
     for ($i = 1; $i <= variable_get('tac_lite_schemes', 1); $i++) {
       $config = _tac_lite_config($i);
       if ($config['name']) {
@@ -454,16 +453,17 @@ function tac_lite_user_presave(&$edit, $account, $category) {
  * terms.
  */
 function tac_lite_node_access_records($node) {
-  // Get the tids we care about that are assigned to this node
+  // Get the tids we care about that are assigned to this node.
   $tids = _tac_lite_get_terms($node);
 
+  // No relevant terms found.
   if (!count($tids)) {
-    // no relevant terms found.
 
-    // in drupal 4-7 we had to write a row into the database. In drupal 5 and later, it should be safe to do nothing.
+    // In drupal 4-7 we had to write a row into the database. In drupal 5 and
+    // later, it should be safe to do nothing.
   }
   else {
-    // if we're here, the node has terms associated with it which restrict
+    // If we're here, the node has terms associated with it which restrict
     // access to the node.
     $grants = array();
     for ($i = 1; $i <= variable_get('tac_lite_schemes', 1); $i++) {
@@ -471,7 +471,8 @@ function tac_lite_node_access_records($node) {
       foreach ($tids as $tid) {
         $grant = array(
           'realm' => $config['realm'],
-          'gid' => $tid, // use term id as grant id
+          // Use term id as grant id.
+          'gid' => $tid,
           'grant_view' => 0,
           'grant_update' => 0,
           'grant_delete' => 0,
@@ -488,24 +489,25 @@ function tac_lite_node_access_records($node) {
 }
 
 /**
- * Gets terms from a node that belong to vocabularies selected for use by tac_lite
+ * Gets terms from a node that belong to vocabularies in use by tac_lite.
+ *
+ * @param object $node
+ *   A node object.
  *
- * @param $node
- *   A node object
- * @return
- *   An array of term ids
+ * @return array
+ *   An array of term ids.
  */
 function _tac_lite_get_terms($node) {
   $tids = array();
 
-  // Get the vids that tac_lite cares about
+  // Get the vids that tac_lite cares about.
   $vids = variable_get('tac_lite_categories', NULL);
   if ($vids) {
-    // Query for all tids assigned to this node in the vids that we care about
+    // Query for all tids assigned to this node in the vids that we care about.
     $query = db_select('taxonomy_index', 'r');
     $t_alias = $query->join('taxonomy_term_data', 't', 'r.tid = t.tid');
     $v_alias = $query->join('taxonomy_vocabulary', 'v', 't.vid = v.vid');
-    $query->fields( $t_alias );
+    $query->fields($t_alias);
     $query->condition("r.nid", $node->nid);
     $query->condition("t.vid", $vids, 'IN');
     $result = $query->execute();
@@ -524,14 +526,16 @@ function _tac_lite_get_terms($node) {
 }
 
 /**
- * Is this used? It will need the same updates as _tac_lite_get_terms
- * @param unknown_type $nid
+ * Is this used? It will need the same updates as _tac_lite_get_terms.
+ *
+ * @param object $nid
+ *   A fully loaded Drupal node object.
  */
 function _tac_lite_get_terms_by_nid($nid) {
   $tids = array();
   $terms = taxonomy_node_get_terms($nid);
 
-  // terms is now an array of objects. We convert to a simple array of tids
+  // Terms is now an array of objects. We convert to a simple array of tids.
   foreach ($terms as $term) {
     $tids[$term->tid] = $term->tid;
   }
@@ -541,10 +545,11 @@ function _tac_lite_get_terms_by_nid($nid) {
 /**
  * Helper function to build a taxonomy term select element for a form.
  *
- * @param $v
+ * @param object $v
  *   A vocabulary object containing a vid and name.
- * @param $default_values
- *   An array of values to use for the default_value argument for this form element.
+ * @param array $default_values
+ *   An array of values to use for the default_value argument for this form
+ *   element.
  */
 function _tac_lite_term_select($v, $default_values = array()) {
   $tree = taxonomy_get_tree($v->vid);
@@ -574,12 +579,15 @@ function _tac_lite_term_select($v, $default_values = array()) {
  * or because of the roles they have.
  */
 function _tac_lite_user_tids($account, $scheme) {
-  // grant id 0 is reserved for nodes which were not given a grant id when they were created. By adding 0 to the grant id, we let the user view those nodes.
+  // Grant id 0 is reserved for nodes which were not given a grant id when they
+  // were created. By adding 0 to the grant id, we let the user view those
+  // nodes.
   $grants = array(0);
   $config = _tac_lite_config($scheme);
   $realm = $config['realm'];
   if (isset($account->data[$realm]) && count($account->data[$realm])) {
-    // $account->$realm is array. Keys are vids, values are array of tids within that vocabulary, to which the user has access
+    // $account->$realm is array. Keys are vids, values are array of tids within
+    // that vocabulary, to which the user has access.
     foreach ($account->data[$realm] as $tids) {
       if (count($tids)) {
         $grants = array_merge($grants, $tids);
@@ -587,7 +595,7 @@ function _tac_lite_user_tids($account, $scheme) {
     }
   }
 
-  // add per-role grants in addition to per-user grants
+  // Add per-role grants in addition to per-user grants.
   $defaults = variable_get('tac_lite_grants_scheme_' . $scheme, array());
   foreach ($account->roles as $rid => $role_name) {
     if (isset($defaults[$rid]) && count($defaults[$rid])) {
@@ -608,7 +616,7 @@ function _tac_lite_user_tids($account, $scheme) {
 }
 
 /**
- * Implementation of hook_node_grants().
+ * Implements hook_node_grants().
  *
  * Returns any grants which may give the user permission to perform the
  * requested op.
@@ -629,13 +637,13 @@ function tac_lite_node_grants($account, $op) {
 /**
  * Implements hook_query_TAG_alter().
  *
- * Acts on queries that list terms (generally these should be tagged with 'term_access')
- * to remove any terms that this user should not be able to see.
+ * Acts on queries that list terms (generally these should be tagged with
+ * 'term_access') to remove any terms that this user should not be able to see.
  */
 function tac_lite_query_term_access_alter(QueryAlterableInterface $query) {
   global $user;
 
-  // If this user has administer rights, don't filter
+  // If this user has administer rights, don't filter.
   if (user_access('administer tac_lite')) {
     return;
   }
@@ -647,7 +655,7 @@ function tac_lite_query_term_access_alter(QueryAlterableInterface $query) {
     return;
   }
 
-  // the terms this user is allowed to see
+  // The terms this user is allowed to see.
   $term_visibility = FALSE;
   $tids = array();
   for ($i = 1; $i <= $schemes; $i++) {
@@ -662,13 +670,14 @@ function tac_lite_query_term_access_alter(QueryAlterableInterface $query) {
     // HELP: What is the proper way to find the alias of the primary table here?
     $primary_table = '';
     $t = $query->getTables();
-    foreach($t as $key => $info) {
+    foreach ($t as $key => $info) {
       if (!$info['join type']) {
         $primary_table = $info['alias'];
       }
     }
 
-    // Prevent query from finding terms the current user does not have permission to see.
+    // Prevent query from finding terms the current user does not have
+    // permission to see.
     $query->leftJoin('taxonomy_term_data', 'tac_td', $primary_table . '.tid = tac_td.tid');
     $or = db_or();
     $or->condition($primary_table . '.tid', $tids, 'IN');
diff --git a/tac_lite_create.module b/tac_lite_create.module
index 6927237..ff25863 100644
--- a/tac_lite_create.module
+++ b/tac_lite_create.module
@@ -10,21 +10,21 @@
  */
 
 /**
- * Implementation of hook_form_alter().
+ * Implements hook_form_alter().
  */
 function tac_lite_create_form_alter(&$form, $form_state, $form_id) {
   if (strpos($form_id, 'node_form') !== FALSE) {
     global $user;
 
     if (user_access('administer tac_lite')) {
-      // no need to restrict based on update permission in this cases
+      // No need to restrict based on update permission in this cases.
       return;
     }
 
-    // the vocabularies containing protected info.
+    // The vocabularies containing protected info.
     $vids = variable_get('tac_lite_categories', array(0));
 
-    // the terms this user is allowed to edit
+    // The terms this user is allowed to edit.
     $tids = array();
     for ($i = 1; $i <= variable_get('tac_lite_schemes', 1); $i++) {
       $config = _tac_lite_config($i);
@@ -34,42 +34,45 @@ function tac_lite_create_form_alter(&$form, $form_state, $form_id) {
       }
     }
 
-    // Go through all of the fields in the system to find the ones we want use
+    // Go through all of the fields in the system to find the ones we want use.
     $term_fields = array();
     $info = field_info_fields();
-    foreach($info as $key => $value){
+    foreach ($info as $key => $value) {
       // First check for taxonomy_term_reference fields.
       if ($value['type'] == 'taxonomy_term_reference') {
-        // Then check to see if they are associated with this node type (entity bundle).
+        // Then check to see if they are associated with this node type
+        // (entity bundle).
         if (isset($value['bundles']['node'])) {
           if (in_array($form['#bundle'], $value['bundles']['node'])) {
-            // Add an entry to our term_fields in the form of field name => vocabulary machine name
+            // Add an entry to our term_fields in the form of field
+            // name => vocabulary machine name.
             $term_fields[$key] = $value['settings']['allowed_values'][0]['vocabulary'];
           }
         }
       }
     }
 
-    // Now that we have the names of the fields, go through each one in the form.
-    foreach($term_fields as $field_name => $vocab_name) {
+    // We have the names of the fields, go through each one in the form.
+    foreach ($term_fields as $field_name => $vocab_name) {
       // Get the language key so we can find the correct element in the field.
       $field_language = $form[$field_name]['#language'];
 
-      // Avoid PHP errors
+      // Avoid PHP errors.
       if (empty($form[$field_name]) || empty($form[$field_name][$field_language])) {
         continue;
       }
 
       // Skip auto complete fields as they are not supported.
-      if ($form[$field_name][$field_language]['#type'] != 'select' && $form[$field_name][$field_language]['#type'] != 'radios'){
+      if ($form[$field_name][$field_language]['#type'] != 'select' && $form[$field_name][$field_language]['#type'] != 'radios') {
         continue;
       }
 
       // Get the vocabulary info so we can get the vid.
       $v = taxonomy_vocabulary_machine_name_load($vocab_name);
 
-      // We only want to act on this field if it is tied to a vocabulary we are set to control.
-      if(!in_array($v->vid, $vids)) {
+      // We only want to act on this field if it is tied to a vocabulary we are
+      // set to control.
+      if (!in_array($v->vid, $vids)) {
         continue;
       }
 
@@ -82,18 +85,21 @@ function tac_lite_create_form_alter(&$form, $form_state, $form_id) {
 
         // Is this option not in the list of terms this user can create with?
         if (!in_array($term_id, $tids)) {
-          // The term is not the default value, and user is not allowed to create with it.
+          // The term is not the default value, and user is not allowed to
+          // create with it.
           // HELP: What if it IS the default value? Do we not unset it?
           if ($term_id != $form[$field_name][$field_language]['#default_value']) {
             // Unset the option to it doesn't appear.
-            // TODO: It would be a nice feature to have tids that are already selected.
-            // go into a value element so we could merge then when saving the node.
+            // TODO: It would be a nice feature to have tids that are already
+            // selected. go into a value element so we could merge then when
+            // saving the node.
             unset($form[$field_name][$field_language]['#options'][$term_id]);
           }
         }
       }
 
-      // If there are no options left, but this field is required then throw a 404.
+      // If there are no options left, but this field is required then
+      // throw a 404.
       if (count($form[$field_name][$field_language]['#options']) == 0 && !empty($form[$field_name]['#required'])) {
         drupal_set_message(t('You have no permissions to add content to the required %name vocabulary. Please contact the site administrator if you believe you should have permission to add content.', array('%name' => $form[$field_name]['#title'])));
         drupal_access_denied();
@@ -104,12 +110,6 @@ function tac_lite_create_form_alter(&$form, $form_state, $form_id) {
       if (count($form[$field_name][$field_language]['#options']) <= 1) {
         $form[$field_name]['#access'] = FALSE;
       }
-      // HELP: Is size deprecated?
-      /*
-      if (isset($form[$field_name]['#size']) && $form[$field_name]['#size'] > count($form['taxonomy'][$field_language]['#options'])) {
-        $form[$field_name]['#size'] = count($form[$field_name][$field_language]['#options']);
-      }
-      */
     }
   }
   elseif ($form_id == 'tac_lite_admin_scheme_form') {
