From 5bf66662a9bdd62c5bccab15e607cd95cfb8fcab Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Mon, 27 Jul 2020 10:05:23 +0200 Subject: Removed wordpress and phpmyadmin, my server doesn't handle it well and it brings shame on my familly --- .../wp-includes/Text/Diff/Engine/xdiff.php | 64 ---------------------- 1 file changed, 64 deletions(-) delete mode 100644 srcs/wordpress/wp-includes/Text/Diff/Engine/xdiff.php (limited to 'srcs/wordpress/wp-includes/Text/Diff/Engine/xdiff.php') diff --git a/srcs/wordpress/wp-includes/Text/Diff/Engine/xdiff.php b/srcs/wordpress/wp-includes/Text/Diff/Engine/xdiff.php deleted file mode 100644 index 02ce848..0000000 --- a/srcs/wordpress/wp-includes/Text/Diff/Engine/xdiff.php +++ /dev/null @@ -1,64 +0,0 @@ - - * @package Text_Diff - */ -class Text_Diff_Engine_xdiff { - - /** - */ - function diff($from_lines, $to_lines) - { - array_walk($from_lines, array('Text_Diff', 'trimNewlines')); - array_walk($to_lines, array('Text_Diff', 'trimNewlines')); - - /* Convert the two input arrays into strings for xdiff processing. */ - $from_string = implode("\n", $from_lines); - $to_string = implode("\n", $to_lines); - - /* Diff the two strings and convert the result to an array. */ - $diff = xdiff_string_diff($from_string, $to_string, count($to_lines)); - $diff = explode("\n", $diff); - - /* Walk through the diff one line at a time. We build the $edits - * array of diff operations by reading the first character of the - * xdiff output (which is in the "unified diff" format). - * - * Note that we don't have enough information to detect "changed" - * lines using this approach, so we can't add Text_Diff_Op_changed - * instances to the $edits array. The result is still perfectly - * valid, albeit a little less descriptive and efficient. */ - $edits = array(); - foreach ($diff as $line) { - if (!strlen($line)) { - continue; - } - switch ($line[0]) { - case ' ': - $edits[] = new Text_Diff_Op_copy(array(substr($line, 1))); - break; - - case '+': - $edits[] = new Text_Diff_Op_add(array(substr($line, 1))); - break; - - case '-': - $edits[] = new Text_Diff_Op_delete(array(substr($line, 1))); - break; - } - } - - return $edits; - } - -} -- cgit