Skip to content

Commit

Permalink
Version 2.1.0
Browse files Browse the repository at this point in the history
Refactor dependencies.
  • Loading branch information
pranavpandey committed Dec 16, 2018
1 parent 2ed405c commit ed79eab
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 17 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ It can be installed by adding the following dependency to your `build.gradle` fi

```groovy
dependencies {
// For AndroidX enabled projects
implementation 'com.pranavpandey.android:dynamic-utils:2.0.0'
// For AndroidX enabled projects.
implementation 'com.pranavpandey.android:dynamic-utils:2.1.0'
// For legacy projects
// For legacy projects.
implementation 'com.pranavpandey.android:dynamic-utils:1.3.0'
}
```
Expand Down
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ buildscript {

dependencies {
classpath 'com.android.tools.build:gradle:3.4.0-alpha08'
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0'
classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
}
}
Expand Down Expand Up @@ -63,8 +63,8 @@ ext {
mavenGroup = 'com.pranavpandey.android'
mavenArtifactId = 'dynamic-utils'
mavenInceptionYear = 2017
mavenVersion = '2.0.0'
mavenVersionCode = 15
mavenVersion = '2.1.0'
mavenVersionCode = 16

developerId = 'pranavpandey'
developerName = 'Pranav Pandey'
Expand Down
6 changes: 2 additions & 4 deletions dynamic-utils/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,12 @@ android {
}

sourceSets {
main.res.srcDirs = [
'src/main/res'
]
main.res.srcDirs 'res'
}
}

dependencies {
implementation "androidx.core:core:${versions.androidx}"
api "androidx.core:core:${versions.androidx}"
}

if (project.rootProject.file('local.properties').exists()) {
Expand Down
3 changes: 2 additions & 1 deletion dynamic-utils/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
limitations under the License.
-->

<manifest package="com.pranavpandey.android.dynamic.utils">
<manifest
package="com.pranavpandey.android.dynamic.utils">

</manifest>
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,8 @@ public class DynamicTaskUtils {
*/
public static void executeTask(@Nullable AsyncTask asyncTask) {
try {
if (asyncTask != null &&
asyncTask.getStatus() != AsyncTask.Status.RUNNING) {
asyncTask.executeOnExecutor(
AsyncTask.THREAD_POOL_EXECUTOR, (Object[]) null);
if (asyncTask != null && asyncTask.getStatus() != AsyncTask.Status.RUNNING) {
asyncTask.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, (Object[]) null);
}
} catch (Exception ignored) {
}
Expand All @@ -52,8 +50,7 @@ public static void executeTask(@Nullable AsyncTask asyncTask) {
*/
public static void cancelTask(@Nullable AsyncTask asyncTask) {
try {
if (asyncTask != null &&
asyncTask.getStatus() == AsyncTask.Status.RUNNING) {
if (asyncTask != null && asyncTask.getStatus() == AsyncTask.Status.RUNNING) {
asyncTask.cancel(true);
}
} catch (Exception ignored) {
Expand Down

0 comments on commit ed79eab

Please sign in to comment.