There is a commented code in the module file which can be removed.

/**
 * Implements hook_entity_info_alter().
 */
//function pdf_using_mpdf_entity_info_alter(&$info) {
//  // Add the 'Print' view mode for nodes.
//  $info['node']['view modes'] += array(
//    'PDF' => array(
//      'label' => t('PDF'),
//      'custom settings' => FALSE,
//    ),
//  );
//}

/**
 * Implements hook_preprocess_node().
 */
//function pdf_using_mpdf_preprocess_node(&$vars) {
//  if ($vars['view_mode'] == 'PDF') {
//    $vars['theme_hook_suggestions'][] = 'node__' . $vars['type'] . '__pdf';
//  }
//}

/**
 * Implements hook_node_view_alter().
 */
//function pdf_using_mpdf_node_view_alter(&$build) {
//  if ($build['#view_mode'] == 'PDF') {
//    // Remove contextual links
//    unset($build['#contextual_links']);
//  }
//}

/**
 *  Get the folder for pdf files.
 */
//function pdf_using_mpdf_get_folder(stdClass $pdfmpdf = NULL) {
//  $folder = &drupal_static(__FUNCTION__);
//  if ( !isset($folder) ) {
//    $folder = variable_get('pdf_using_mpdf', 'pdf_using_mpdf');
//  }
//  if ( !empty($pdfmpdf->smid) ) {
//    return file_build_uri($folder . '/' . $pdfmpdf->smid);
//  }
//  else {
//    return file_build_uri($folder);
//  }
//}

Comments

rajeevgole created an issue. See original summary.

rajeevgole’s picture

Status: Active » Needs review
StatusFileSize
new1.47 KB
avpaderno’s picture

Version: 8.x-1.0-alpha2 » 8.x-1.x-dev
Status: Needs review » Postponed

Also _pdf_using_mpdf_attributes_access() should be removed, since it is not used in any place.

Given the actual committed code, and the fact that the only controller method associated with a route is actually doing nothing (see GeneratePdf::generate()), simply removing code that is already commented out is probably the last of the tasks to do.

The code that needs to be changed is the one for the Drupal 8 branch (i.e. the development snapshot).

avpaderno’s picture

Status: Postponed » Closed (won't fix)

See comment #3 on the other issue.