File tree 2 files changed +4
-1
lines changed
src/main/java/com/amazonaws/encryptionsdk 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,7 @@ public List<K> getMasterKeys() {
69
69
}
70
70
71
71
/** Convenience method for retrieving the keyIds in the results from {@link #getMasterKeys()}. */
72
+ @ Deprecated
72
73
public List <String > getMasterKeyIds () {
73
74
final List <String > result = new ArrayList <>(masterKeys_ .size ());
74
75
for (final MasterKey <K > mk : masterKeys_ ) {
Original file line number Diff line number Diff line change @@ -890,7 +890,9 @@ public CiphertextHeaders getHeaders() {
890
890
891
891
@ Override
892
892
public List <K > getMasterKeys () {
893
- return Collections .singletonList (dataKey_ .getMasterKey ());
893
+ return dataKey_ .getMasterKey () == null
894
+ ? Collections .emptyList ()
895
+ : Collections .singletonList (dataKey_ .getMasterKey ());
894
896
}
895
897
896
898
@ Override
You can’t perform that action at this time.
0 commit comments