Index: inc/extras.php
===================================================================
--- inc/extras.php	(revision 3265)
+++ inc/extras.php	(working copy)
@@ -96,8 +96,10 @@
  * @return string
  */
 function wporg_filter_archive_excerpt( $excerpt ) {
-	if ( ! is_single() && ! wporg_is_handbook() ) {
+	$wporg_is_handbook = function_exists( 'wporg_is_handbook' ) ? wporg_is_handbook() : false;
 
+	if ( ! is_single() && ! $wporg_is_handbook ) {
+
 		$post_id = get_the_ID();
 		$type    = get_post_type_object( get_post_type( $post_id ) )->labels->singular_name;
 
Index: inc/redirects.php
===================================================================
--- inc/redirects.php	(revision 3265)
+++ inc/redirects.php	(working copy)
@@ -32,7 +32,9 @@
 	 * Redirects a search query with only one result directly to that result.
 	 */
 	public static function redirect_single_search_match() {
-		if ( is_search() && ! wporg_is_handbook() && 1 == $GLOBALS['wp_query']->found_posts ) {
+		$wporg_is_handbook = function_exists( 'wporg_is_handbook' ) ? wporg_is_handbook() : false;
+
+		if ( is_search() && ! $wporg_is_handbook && 1 == $GLOBALS['wp_query']->found_posts ) {
 			wp_redirect( get_permalink( get_post() ) );
 			exit();
 		}
Index: inc/search.php
===================================================================
--- inc/search.php	(revision 3265)
+++ inc/search.php	(working copy)
@@ -43,7 +43,9 @@
 
 		// Separates searches for handbook pages from non-handbook pages depending on
 		// whether the search was performed within context of a handbook page or not.
-		if ( wporg_is_handbook() ) {
+		$wporg_is_handbook = function_exists( 'wporg_is_handbook' ) ? wporg_is_handbook() : false;
+
+		if ( $wporg_is_handbook ) {
 			// Search only in current handbook post type.
 			// Just to make sure. post type should already be set.
 			$query->set( 'post_type', wporg_get_current_handbook() );
Index: inc/user-content.php
===================================================================
--- inc/user-content.php	(revision 3265)
+++ inc/user-content.php	(working copy)
@@ -62,7 +62,9 @@
 	 */
 	public static function scripts_and_styles() {
 		if ( is_singular() ) {
-			if ( '0' != get_comments_number() || \DevHub\post_type_has_source_code() || wporg_is_handbook_post_type() ) {
+			$is_handbook_post_type = function_exists( 'wporg_is_handbook_post_type' ) ? wporg_is_handbook_post_type() : false;
+
+			if ( '0' != get_comments_number() || \DevHub\post_type_has_source_code() || $is_handbook_post_type ) {
 				wp_enqueue_script( 'wporg-developer-function-reference', get_template_directory_uri() . '/js/function-reference.js', array( 'jquery', 'syntaxhighlighter-core', 'syntaxhighlighter-brush-php' ), '20150319', true );
 				wp_enqueue_style( 'syntaxhighlighter-core' );
 				wp_enqueue_style( 'syntaxhighlighter-theme-default' );
Index: searchform.php
===================================================================
--- searchform.php	(revision 3265)
+++ searchform.php	(working copy)
@@ -34,7 +34,7 @@
 <?php } ?>
 
 	<?php
-		$is_handbook = wporg_is_handbook();
+		$is_handbook = function_exists( 'wporg_is_handbook' ) ? wporg_is_handbook() : false;
 		$search_url  = $is_handbook ? wporg_get_current_handbook_home_url() : home_url( '/' );
 		$form_class  = $is_handbook ? ' searchform-handbook' : '';
 	?>
