Skip to content

Commit

Permalink
1.3.2 릴리즈
Browse files Browse the repository at this point in the history
사진을 업로드 할 수 없던 버그 수정
  • Loading branch information
JellyBrick committed Nov 13, 2019
1 parent a2b6377 commit 42e8a96
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 9 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
### Gradle

```
compile 'be.zvz:KotlinInside:1.3.1'
compile 'be.zvz:KotlinInside:1.3.2'
```

### Maven
Expand All @@ -16,14 +16,15 @@ compile 'be.zvz:KotlinInside:1.3.1'
<dependency>
<groupId>be.zvz</groupId>
<artifactId>KotlinInside</artifactId>
<version>1.3.1</version>
<version>1.3.2</version>
<type>pom</type>
</dependency>
```

### 라이브러리 사용

**Java 1.7 (Java 7)** 이상 필요
**Kotlin 1.3+** 권장

### 라이브러리 컴파일

Expand Down
10 changes: 6 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ apply plugin: 'com.jfrog.bintray'
apply plugin: 'com.github.dcendents.android-maven'

def libName = 'KotlinInside'
def libVersion = '1.3.1'
def libVersion = '1.3.2'
def libDesc = 'Unofficial DCInside API written in Kotlin'

group = 'be.zvz'
Expand All @@ -30,8 +30,10 @@ repositories {
jcenter()
}

sourceCompatibility = JavaVersion.VERSION_1_7
targetCompatibility = JavaVersion.VERSION_1_7
compileJava {
sourceCompatibility = JavaVersion.VERSION_1_7
targetCompatibility = JavaVersion.VERSION_1_7
}

dependencies {
implementation group: 'commons-codec', name: 'commons-codec', version: '1.13'
Expand All @@ -48,7 +50,7 @@ dependencies {
implementation group: 'com.vladsch.flexmark', name: 'flexmark-ext-gfm-tasklist', version: '0.50.42'

// Use the Kotlin JDK standard library.
implementation group: 'org.jetbrains.kotlin', name: 'kotlin-stdlib'
implementation group: 'org.jetbrains.kotlin', name: 'kotlin-stdlib-jdk7'
// Use the Kotlin test library.
testImplementation group: 'org.jetbrains.kotlin', name: 'kotlin-test'
// Use the Kotlin JUnit integration.
Expand Down
10 changes: 7 additions & 3 deletions src/main/java/be/zvz/kotlininside/http/DefaultHttpClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import java.io.File;
import java.io.IOException;
import java.io.UnsupportedEncodingException;
import java.net.URLConnection;
import java.net.URLEncoder;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -200,11 +201,14 @@ public JsonBrowser upload(@NotNull String url, @Nullable Option option) throws H
}

for (Map.Entry<String, File> entry : option.getMultipartFile().entrySet()) {
request.part(entry.getKey(), entry.getValue());
File file = entry.getValue();
request.part(entry.getKey(), file.getName(), URLConnection.guessContentTypeFromName(file.toString()), file);
}

for (Map.Entry<String, List<File>> ignored : option.getMultipartFileList().entrySet()) {
throw new UnsupportedOperationException("Not implemented yet");
for (Map.Entry<String, List<File>> entry : option.getMultipartFileList().entrySet()) {
for (File file : entry.getValue()) {
request.part(entry.getKey(), file.getName(), URLConnection.guessContentTypeFromName(file.toString()), file);
}
}
}

Expand Down

0 comments on commit 42e8a96

Please sign in to comment.