Skip to content

Commit

Permalink
Issue #SB-10842 fix: Fixed null pointer exception
Browse files Browse the repository at this point in the history
  • Loading branch information
AmiableAnil committed Mar 13, 2019
1 parent 471c4a3 commit d30ae14
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/android/org/sunbird/ImportExportUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ private static String getRelevantMessage(String localeSelected) {

private static boolean importGenieSupportedFile(Activity activity, final IImport delegate, final String filePath,
final boolean isAttachment, boolean showProgressDialog) {
String extension = getFileExtension(filePath);
localeSelected = GenieService.getService().getKeyStore().getString("sunbirdselected_language_code", "en");

if (!isValidExtension(filePath)) {
Expand All @@ -90,6 +89,8 @@ private static boolean importGenieSupportedFile(Activity activity, final IImport
return false;
}

String extension = getFileExtension(filePath);

if (extension.equalsIgnoreCase("ecar")) {
importContent(activity, filePath, new ImportExportUtil.IImport() {
@Override
Expand Down Expand Up @@ -285,3 +286,4 @@ public interface IImport {
void onOutDatedEcarFound();
}
}

0 comments on commit d30ae14

Please sign in to comment.