diff options
author | Daniel Friesel <derf@finalrewind.org> | 2014-11-07 10:24:51 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2014-11-07 10:24:51 +0100 |
commit | 6fcf4d3f96b8855172fbe12a7b4c1ddc14c35d33 (patch) | |
tree | 6c6e5fae122a90e99d5b167c37deee06e6c2c287 | |
parent | 074cce7083a964c9b60295c1cea1986c7c598c6f (diff) |
index: only call is_canceled if the backend module supports it
-rw-r--r-- | index.pl | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -253,9 +253,11 @@ sub handle_request { destination => $result->destination, platform => $platform, info => $info, - is_cancelled => $result->is_cancelled, - moreinfo => $moreinfo, - delay => $delay, + is_cancelled => $result->can('is_canceled') + ? $result->is_cancelled + : undef, + moreinfo => $moreinfo, + delay => $delay, } ); } |