Skip to content

Commit

Permalink
use an empty map if the env is null
Browse files Browse the repository at this point in the history
  • Loading branch information
brharrington committed Jun 30, 2015
1 parent 271c63c commit fd6628e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
import java.net.HttpURLConnection;
import java.net.URL;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
Expand All @@ -57,7 +58,7 @@ public class SidecarRegistry extends AbstractRegistry {
@Override public Map<String, String> call() throws Exception {
SparkEnv env = SparkEnv$.MODULE$.get();
if (env == null) {
return null;
return Collections.emptyMap();
} else {
Map<String, String> tagMap = new HashMap<>();
SparkConf conf = env.conf();
Expand Down

0 comments on commit fd6628e

Please sign in to comment.