From 6468254994fa37b8a743d34f0d1e233335ccbc29 Mon Sep 17 00:00:00 2001 From: life Date: Sun, 8 Nov 2015 16:02:43 +0800 Subject: [PATCH] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E4=BD=BF=E7=94=A8leanote=20?= =?UTF-8?q?=20https?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Leanote/service/UserService.m | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Leanote/service/UserService.m b/Leanote/service/UserService.m index e939e5c..4b66c17 100644 --- a/Leanote/service/UserService.m +++ b/Leanote/service/UserService.m @@ -15,7 +15,7 @@ #import "TagService.h" static NSString* const UserT = @"User"; // 表名 -static NSString* const DefaultHost = @"http://leanote.com"; // @"http://localhost:9000"; // 默认host +static NSString* const DefaultHost = @"https://leanote.com"; // @"http://localhost:9000"; // 默认host static User *curUser; @@ -57,6 +57,12 @@ static BOOL openInited; if([Common isBlankString:curUser.host]) { return DefaultHost; } + + // 如果是http://leanote.com, 则改成https + NSString *host = curUser.host; + if ([host isEqualToString:@"http://leanote.com"]) { + return DefaultHost; + } return curUser.host; // return @"http://localhost:9000"; }