From: Tim Düsterhus Date: Fri, 12 Dec 2014 00:26:41 +0000 (+0100) Subject: Fix possible undefined index notice in SQLParser X-Git-Tag: 2.1.0_Beta_1~69 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cceec271ea30ba144c998ef75634d0a4ce55a0b5;p=GitHub%2FWoltLab%2FWCF.git Fix possible undefined index notice in SQLParser --- diff --git a/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php b/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php index c168898963..052a0c20a2 100644 --- a/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php +++ b/wcfsetup/install/files/lib/system/database/util/SQLParser.class.php @@ -125,8 +125,8 @@ class SQLParser { 'columns' => $match[3], 'referencedTable' => $match[4], 'referencedColumns' => $match[5], - 'ON DELETE' => $match[6], - 'ON UPDATE' => $match[7] + 'ON DELETE' => isset($match[6]) ? $match[6] : '', + 'ON UPDATE' => isset($match[7]) ? $match[7] : '' )); } // add/change column