diff --git a/config.yml b/config.yml index e0fefed..fd601ab 100644 --- a/config.yml +++ b/config.yml @@ -32,6 +32,9 @@ show_errors: 1 expiration: weeks: 2 +strings: + default_expiry: "Two weeks" + # Languages supported by Pygments # TODO: perhaps swap this out with something in App::WerePaste::Util::PygmentsBridge so we can dynamically load supported languages diff --git a/lib/App/WerePaste.pm b/lib/App/WerePaste.pm index e63f6e6..89f2d88 100644 --- a/lib/App/WerePaste.pm +++ b/lib/App/WerePaste.pm @@ -51,7 +51,7 @@ sub ValidateParams { sub GetPaste { my $id = shift; $id = lc $id; return undef unless $id =~ /^[a-f0-9]*$/; - return schema->resultset('Paste')->single({ id => $id }) || undef; + return schema->resultset('Paste')->single({ id => $id }); } sub StorePaste { my $params = shift; diff --git a/views/index.tt b/views/index.tt index bbf750d..2e90a00 100644 --- a/views/index.tt +++ b/views/index.tt @@ -17,13 +17,14 @@