Fix possible undefined index notice in SQLParser
authorTim Düsterhus <duesterhus@woltlab.com>
Fri, 12 Dec 2014 00:26:41 +0000 (01:26 +0100)
committerTim Düsterhus <duesterhus@woltlab.com>
Fri, 12 Dec 2014 00:26:41 +0000 (01:26 +0100)
wcfsetup/install/files/lib/system/database/util/SQLParser.class.php

index c168898963b3b4d4580012bfe3555d05d99f16bd..052a0c20a22239d35453d99a44610df6ac47aee6 100644 (file)
@@ -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