Mysqli errors: Trying to access array offset on value of type bool. Fixed. Please...
[fa-stable.git] / inventory / manage / sales_kits.php
index c8a80687dfc098d7eb6077d4b75301cedde2548a..849564dd75c32792a44e53862c10867e29e31d84 100644 (file)
@@ -224,8 +224,8 @@ if (get_post('item_code') == '') {
 
        if (get_post('item_code') == '') { // new kit/alias
                if ($Mode!='ADD_ITEM' && $Mode!='UPDATE_ITEM') {
-                       $_POST['description'] = $props['description'];
-                       $_POST['category'] = $props['category_id'];
+                       $_POST['description'] = is_array($props) ? $props['description'] : '';
+                       $_POST['category'] = is_array($props) ? $props['category_id'] : '';
                }
                text_row(_("Description:"), 'description', null, 50, 200);
                stock_categories_list_row(_("Category:"), 'category', null);