mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 01:46:00 +00:00
update-feed: exit with non-zero exit code if update_rss_feed() failed
daemon: log if per-feed update task terminated with non-zero exit code
This commit is contained in:
@@ -260,12 +260,17 @@
|
||||
|
||||
if (isset($options["update-feed"])) {
|
||||
try {
|
||||
RSSUtils::update_rss_feed($options["update-feed"], true);
|
||||
|
||||
if (!RSSUtils::update_rss_feed($options["update-feed"], true))
|
||||
exit(100);
|
||||
|
||||
} catch (PDOException $e) {
|
||||
Debug::log(sprintf("Exception while updating feed %d: %s (%s:%d)",
|
||||
$options["update-feed"], $e->getMessage(), $e->getFile(), $e->getLine()));
|
||||
|
||||
Logger::get()->log_error(E_USER_NOTICE, $e->getMessage(), $e->getFile(), $e->getLine(), $e->getTraceAsString());
|
||||
|
||||
exit(110);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user