Skip to content

Commit

Permalink
Replace @@missing@@ when source is missing (#838)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheoChevalier authored and flodolo committed Jan 17, 2017
1 parent fb20508 commit 2876888
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion app/classes/Transvision/ShowResults.php
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,9 @@ public static function resultsTable($search_object, $search_results, $page)
$meta_source = $meta_target = $meta_target2 = '';

// If there is no source_string, display an error, otherwise display the string + meta links
if (! $source_string) {
if ($source_string == '@@missing@@') {
$source_string = '<em class="error">Warning: Source string is missing</em>';
} elseif (! $source_string) {
$source_string = '<em class="error">Warning: Source string is empty</em>';
} else {
$meta_source = "
Expand Down
4 changes: 3 additions & 1 deletion app/views/results_entities.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,9 @@
$error_message = ShowResults::buildErrorString($source_string, $target_string);

// If there is no source_string, display an error, otherwise display the string + meta links
if (! $source_string) {
if ($source_string == '@@missing@@') {
$source_string = '<em class="error">Warning: Source string is missing</em>';
} elseif (! $source_string) {
$source_string = '<em class="error">Warning: Source string is empty</em>';
} else {
$meta_source = "
Expand Down

0 comments on commit 2876888

Please sign in to comment.