Forráskód Böngészése

如果是巨量账户级,推广id和巨量账户唯一绑定

liuzejian 1 éve
szülő
commit
de01f4ce39

+ 1 - 1
modules/Tuiguang/Http/Controllers/PromotionController.php

@@ -133,7 +133,7 @@ class PromotionController extends CatchController
                 ->where(['is_enabled' => 1, 'callback_type' => $request->input('callback_type'),
                     'callback_config_id' => $request->input('callback_config_id')])
                 ->first();
-            if($exist->id != $request->input('id')) {
+            if($exist && $exist->id != $request->input('id')) {
                 CommonBusinessException::throwError(Errors::JULIANG_ACCOUNT_PROMOTION_UNIQUE);
             }
         }