Changeset 906
- Timestamp:
- 12/09/06 17:13:37 (2 years ago)
- Files:
-
- 1 modified
-
trunk/lib/OpenGuides.pm (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/lib/OpenGuides.pm
r901 r906 196 196 197 197 # Fixes passing undefined values to Text::Wikiformat if node doesn't exist. 198 my $raw = $node_data{content} || " "; 199 my $content = $wiki->format($raw); 198 my $content = ''; 199 if ($node_data{content}) { 200 $content = $wiki->format($node_data{content}); 201 } 202 200 203 my $modified = $node_data{last_modified}; 201 204 my $moderated = $node_data{moderated}; … … 207 210 config => $config); 208 211 if ($args{format} && $args{format} eq 'raw') { 209 print "Content-Type: text/plain\n\n";210 print $raw;211 return 0;212 print "Content-Type: text/plain\n\n"; 213 print $node_data{content}; 214 return 0; 212 215 } 213 216 … … 241 244 $tt_vars{catloc_link} = $config->script_name . "?id="; 242 245 } 243 244 if ( $ raw=~ /^#REDIRECT\s+(.+?)\s*$/ ) {246 247 if ( $node_data{content} && $node_data{content} =~ /^#REDIRECT\s+(.+?)\s*$/ ) { 245 248 my $redirect = $1; 246 249 # Strip off enclosing [[ ]] in case this is an extended link.
