DESKTOP-2STQMTS\Administrator hace 3 años
padre
commit
36d06b0722
Se han modificado 1 ficheros con 3 adiciones y 0 borrados
  1. 3 0
      app/Servers/Member/UserServer.php

+ 3 - 0
app/Servers/Member/UserServer.php

@@ -42,6 +42,9 @@ class UserServer
             //查找推广者
             if ($invite_code){
                 $p_id = WxUser::where('invite_code', $invite_code)->value('id');
+                if(!$p_id){
+                    $p_id = 0;
+                }
             }else{
                 $p_id = 0;//找不到推广上级就为0既是上级为平台
             }