better handle PDOExceptions during open transaction in feed update

master
Andrew Dolgov 6 years ago
parent 5f66f872b6
commit 2c940c4861

@ -192,6 +192,13 @@ class RSSUtils {
RSSUtils::update_rss_feed($tline["id"], true, false);
} catch (PDOException $e) {
Logger::get()->log_error(E_USER_NOTICE, $e->getMessage(), $e->getFile(), $e->getLine(), $e->getTraceAsString());
try {
$pdo->rollback();
} catch (PDOException $e) {
// it doesn't matter if there wasn't actually anything to rollback, PDO Exception can be
// thrown outside of an active transaction during feed update
}
}
_debug_suppress(false);

Loading…
Cancel
Save