Skip to content

Commit

Permalink
Update BaggageBuffersContents.java
Browse files Browse the repository at this point in the history
Add bagKey null check
  • Loading branch information
JonathanMace committed Jul 8, 2020
1 parent 7fd3289 commit 917af24
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -74,7 +74,7 @@ public class BaggageBuffersContents implements BaggageContents {

/** Get the value mapped to a key, or null if no mapping */
public Bag get(BagKey key) {
return bags == null ? null : bags.get(key);
return (bags == null || key == null) ? null : bags.get(key);
}

/** Remove the mapping for the specified key. Returns this object */
Expand Down

0 comments on commit 917af24

Please sign in to comment.