From 607072acd1cdbdd47617a94927b4063e3f3d09e1 Mon Sep 17 00:00:00 2001 From: William Patton Date: Fri, 12 Oct 2018 23:16:53 +0100 Subject: [PATCH] Prevent modifications to read_more affecting dashboard expected behavior --- inc/setup.php | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/inc/setup.php b/inc/setup.php index 69d0aab..59890ff 100644 --- a/inc/setup.php +++ b/inc/setup.php @@ -110,7 +110,10 @@ if ( ! function_exists( 'understrap_custom_excerpt_more' ) ) { * @return string */ function understrap_custom_excerpt_more( $more ) { - return ''; + if ( ! is_admin() ) { + $more = ''; + } + return $more; } } @@ -125,8 +128,10 @@ if ( ! function_exists( 'understrap_all_excerpts_get_more_link' ) ) { * @return string */ function understrap_all_excerpts_get_more_link( $post_excerpt ) { - - return $post_excerpt . ' [...]

' . __( 'Read More...', - 'understrap' ) . '

'; + if ( ! is_admin() ) { + $post_excerpt = $post_excerpt . ' [...]

' . __( 'Read More...', + 'understrap' ) . '

'; + } + return $post_excerpt; } -} \ No newline at end of file +}