diff --git a/CASA/policy/PersistencePol.cs b/CASA/policy/PersistencePol.cs index 6b15334a..9573d60a 100644 --- a/CASA/policy/PersistencePol.cs +++ b/CASA/policy/PersistencePol.cs @@ -132,12 +132,15 @@ public class PersistencePol : CASAPol ArrayList al = new ArrayList(); //enumerate all secrets loaded - IDictionaryEnumerator idEnum = htSecretPolicys.GetEnumerator(); - while (idEnum.MoveNext()) + if (htSecretPolicys != null) { - string sSecretID = (string)idEnum.Key; - al.Add(sSecretID); - } + IDictionaryEnumerator idEnum = htSecretPolicys.GetEnumerator(); + while (idEnum.MoveNext()) + { + string sSecretID = (string)idEnum.Key; + al.Add(sSecretID); + } + } return al; }