Skip to content

Commit

Permalink
fix: https 连接端口错误
Browse files Browse the repository at this point in the history
https 站点端口错误,导致302重定向问题
  • Loading branch information
renfei committed Mar 4, 2021
1 parent dba97ef commit a2119c6
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ GPLv2具有很强的传染性,选用这个开源协议并不是我定的,而
<dependency>
<groupId>net.renfei</groupId>
<artifactId>discuz-ucenter-api-for-java</artifactId>
<version>1.0.3</version>
<version>1.0.4</version>
</dependency>
```

如果你使用的是传统方式,需要下载```Jar```包,放入```lib```文件夹,下载地址:[discuz-ucenter-api-for-java-1.0.3.jar
](https://github.com/renfei/discuz-ucenter-api-for-java/releases/download/1.0.3/discuz-ucenter-api-for-java-1.0.3.jar)
如果你使用的是传统方式,需要下载```Jar```包,放入```lib```文件夹,下载地址:[discuz-ucenter-api-for-java-1.0.4.jar
](https://github.com/renfei/discuz-ucenter-api-for-java/releases/download/1.0.4/discuz-ucenter-api-for-java-1.0.4.jar)

## 使用

Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>net.renfei</groupId>
<artifactId>discuz-ucenter-api-for-java</artifactId>
<version>1.0.3</version>
<version>1.0.4</version>
<packaging>jar</packaging>
<name>discuz-ucenter-api-for-java</name>
<url>https://github.com/renfei/discuz-ucenter-api-for-java</url>
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/net/renfei/discuz/ucenter/client/Client.java
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,8 @@ protected String ucFopen(String url, int limit, String post, String cookie, bool
path = matches.getPath() != null ? matches.getPath() + (matches.getQuery() != null ? "?" + matches.getQuery() : "") : "/";
if (matches.getPort() > 0) {
port = matches.getPort();
} else if ("https".equals(matches.getProtocol().toLowerCase())) {
port = 443;
}
} catch (MalformedURLException e1) {
e1.printStackTrace();
Expand Down

0 comments on commit a2119c6

Please sign in to comment.