diff -Naur old/theme-editor.php new/theme-editor.php
--- old/theme-editor.php	2018-09-04 16:40:46.004811000 +0530
+++ new/theme-editor.php	2018-09-04 16:57:31.653460229 +0530
@@ -319,11 +319,15 @@
 				<h1><?php _e( 'Heads up!' ); ?></h1>
 				<p>
 					<?php
-					echo sprintf(
-						/* translators: %s: Codex URL */
-						__( 'You appear to be making direct edits to your theme in the WordPress dashboard. We recommend that you don&#8217;t! Editing your theme directly could break your site and your changes may be lost in future updates. If you need to tweak more than your theme&#8217;s CSS, you might want to try <a href="%s">making a child theme</a>.' ),
-						esc_url( __( 'https://codex.wordpress.org/Child_Themes' ) )
-					);
+					if( $theme->parent() ) {
+						_e( 'You appear to be making direct edits to your theme in the WordPress dashboard. We recommend that you don&#8217;t! Editing your theme directly could break.' );
+					} else {
+						echo sprintf(
+							/* translators: %s: Codex URL */
+							__( 'You appear to be making direct edits to your theme in the WordPress dashboard. We recommend that you don&#8217;t! Editing your theme directly could break your site and your changes may be lost in future updates. If you need to tweak more than your theme&#8217;s CSS, you might want to try <a href="%s">making a child theme</a>.' ),
+							esc_url( __( 'https://codex.wordpress.org/Child_Themes' ) )
+						);
+					}
 					?>
 				</p>
 				<p><?php _e( 'If you decide to go ahead with direct edits anyway, use a file manager to create a copy with a new name and hang on to the original. That way, you can re-enable a functional version if something goes wrong.' ); ?></p>
@@ -339,4 +343,4 @@
 <?php
 endif; // editor warning notice
 
-include(ABSPATH . 'wp-admin/admin-footer.php' );
+include(ABSPATH . 'wp-admin/admin-footer.php' );
\ No newline at end of file
