Skip to content

Commit

Permalink
Merge branch 'release/1.4.5'
Browse files Browse the repository at this point in the history
  • Loading branch information
prof18 committed Dec 8, 2018
2 parents 420dbe8 + 8436da8 commit 7120af1
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ android {
applicationId "com.prof.rssparser.example"
minSdkVersion 14
targetSdkVersion 27
versionCode 5
versionName "1.2.2"
versionCode 6
versionName "1.2.3"
}
buildTypes {
release {
Expand All @@ -22,7 +22,7 @@ dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
testImplementation 'junit:junit:4.12'
implementation project(":rssparser")
// implementation 'com.prof.rssparser:rssparser:1.4.4'
// implementation 'com.prof.rssparser:rssparser:1.4.5'
implementation 'com.android.support:appcompat-v7:27.1.0'
implementation 'com.android.support:design:27.1.0'
implementation 'com.android.support:recyclerview-v7:27.1.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public void onTaskCompleted(ArrayList<Article> list) {

//what to do in case of error
@Override
public void onError() {
public void onError(Exception exception) {

runOnUiThread(new Runnable() {
@Override
Expand Down
4 changes: 2 additions & 2 deletions rssparser/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ android {
defaultConfig {
minSdkVersion 14
targetSdkVersion 27
versionCode 8
versionName "1.4.4"
versionCode 9
versionName "1.4.5"
}

buildTypes {
Expand Down
2 changes: 1 addition & 1 deletion rssparser/publish.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apply plugin: 'maven-publish'
apply plugin: 'com.jfrog.bintray'

version '1.4.4'
version '1.4.5'
group 'com.prof.rssparser'

publishing {
Expand Down
8 changes: 4 additions & 4 deletions rssparser/src/main/java/com/prof/rssparser/Parser.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public Parser() {
public interface OnTaskCompleted {
void onTaskCompleted(ArrayList<Article> list);

void onError();
void onError(Exception exception);
}

public void onFinish(OnTaskCompleted onComplete) {
Expand All @@ -69,7 +69,7 @@ protected String doInBackground(String... ulr) {
return response.body().string();
} catch (IOException e) {
e.printStackTrace();
onComplete.onError();
onComplete.onError(e);
}
return null;
}
Expand All @@ -83,10 +83,10 @@ protected void onPostExecute(String result) {
Log.i("RSS Parser ", "RSS parsed correctly!");
} catch (Exception e) {
e.printStackTrace();
onComplete.onError();
onComplete.onError(e);
}
} else
onComplete.onError();
onComplete.onError(new Exception("RSS parse operation returned null"));
}

@Override
Expand Down

0 comments on commit 7120af1

Please sign in to comment.