Sfoglia il codice sorgente

更新 'src/Applet.php'

rabin 7 anni fa
parent
commit
40d2a95a0f
1 ha cambiato i file con 9 aggiunte e 1 eliminazioni
  1. 9 1
      src/Applet.php

+ 9 - 1
src/Applet.php

@@ -8,6 +8,13 @@ use Passport\Src\Lib\Base;
 
 class Applet extends Base
 {
+  	public function init()
+    {
+      	$uid = $this->check();
+        $user = Dever::load('passport/user-one', $uid);
+
+        return $user;
+    }
     /**
      * 用户绑定 生成用户信息
      *
@@ -228,7 +235,8 @@ class Applet extends Base
             }
             
             if ($pic) {
-                $update['set_avatar'] = $this->saveAvatar($pic);
+                //$update['set_avatar'] = $this->saveAvatar($pic);
+              	$update['set_avatar'] = $pic;
             }
             
             //$update['set_city'] = $city;