/[webpac2]/Webpacus/lib/Webpacus/Controller/Editor.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /Webpacus/lib/Webpacus/Controller/Editor.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 243 by dpavlin, Wed Dec 14 23:04:05 2005 UTC revision 244 by dpavlin, Wed Dec 14 23:04:13 2005 UTC
# Line 41  sub default : Private { Line 41  sub default : Private {
41    
42          $c->stash->{template_filename} = $template_filename;          $c->stash->{template_filename} = $template_filename;
43    
44            $c->stash->{databases} = $c->config->{databases} or
45                    $c->log->fail("didn't find databases in config");
46    
47          $c->stash->{template} = 'editor.tt';          $c->stash->{template} = 'editor.tt';
48  }  }
49    
# Line 157  sub record : Local { Line 160  sub record : Local {
160          $c->log->debug('record params '.Dumper($c->req->params));          $c->log->debug('record params '.Dumper($c->req->params));
161    
162          my $record_uri = $c->req->params->{record_uri};          my $record_uri = $c->req->params->{record_uri};
163            $record_uri ||= $c->config->{editor}->{default_record_uri} and
164                    $c->log->warn("using editor: default_record_uri");
165    
166          if (! $record_uri) {          if (! $record_uri) {
167                  $c->log->fatal("no record_uri");                  $c->log->fatal("record called without record_uri and default_record_uri not found in config under editor");
168                  $c->stash->{error} = 'record retrival failed';                  $c->stash->{error} = 'record retrival failed';
169                  $c->stash->{template} = 'error.tt';                  $c->stash->{template} = 'error.tt';
170                  return;                  return;

Legend:
Removed from v.243  
changed lines
  Added in v.244

  ViewVC Help
Powered by ViewVC 1.1.26