Changeset View
Changeset View
Standalone View
Standalone View
src/applications/differential/storage/DifferentialHunk.php
| Show First 20 Lines • Show All 51 Lines • ▼ Show 20 Lines | public function getContentWithMask($mask) { | ||||
| $include = implode('', $include); | $include = implode('', $include); | ||||
| return implode('', $this->makeContent($include)); | return implode('', $this->makeContent($include)); | ||||
| } | } | ||||
| final private function makeContent($include) { | final private function makeContent($include) { | ||||
| $results = array(); | $results = array(); | ||||
| $lines = explode("\n", $this->changes); | $lines = explode("\n", $this->getChanges()); | ||||
| // NOTE: To determine whether the recomposed file should have a trailing | // NOTE: To determine whether the recomposed file should have a trailing | ||||
| // newline, we look for a "\ No newline at end of file" line which appears | // newline, we look for a "\ No newline at end of file" line which appears | ||||
| // after a line which we don't exclude. For example, if we're constructing | // after a line which we don't exclude. For example, if we're constructing | ||||
| // the "new" side of a diff (excluding "-"), we want to ignore this one: | // the "new" side of a diff (excluding "-"), we want to ignore this one: | ||||
| // | // | ||||
| // - x | // - x | ||||
| // \ No newline at end of file | // \ No newline at end of file | ||||
| ▲ Show 20 Lines • Show All 69 Lines • Show Last 20 Lines | |||||