diff options
author | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-06-01 05:38:23 +0000 |
---|---|---|
committer | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-06-01 05:38:23 +0000 |
commit | 7b0b142202fde91770e2840e3afc7ba80fe656f1 (patch) | |
tree | ebee9709585ff3007ae36f98eba269000ac39e59 /lib | |
parent | 0d8e43fea5f354cbadd5feba27859622bbe85f78 (diff) | |
download | ampache-7b0b142202fde91770e2840e3afc7ba80fe656f1.tar.gz ampache-7b0b142202fde91770e2840e3afc7ba80fe656f1.tar.bz2 ampache-7b0b142202fde91770e2840e3afc7ba80fe656f1.zip |
additional error checking on catalog so it does not fail silently
Diffstat (limited to 'lib')
-rw-r--r-- | lib/class/catalog.class.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php index b8e49855..962e9dc0 100644 --- a/lib/class/catalog.class.php +++ b/lib/class/catalog.class.php @@ -169,6 +169,12 @@ class Catalog { $insert_id = Dba::insert_id(); + if (!$insert_id) { + Error::add('general','Catalog Insert Failed check debug logs'); + debug_event('catalog','SQL Failed:' . $sql,'3'); + return false; + } + return $insert_id; } // create |