Address sonar issues in models
[policy/models.git] / models-base / src / main / java / org / onap / policy / models / base / PfTimestampKey.java
index a2f1129..5be9b5f 100644 (file)
@@ -3,6 +3,7 @@
  * ONAP Policy Model
  * ================================================================================
  * Copyright (C) 2019 Nordix Foundation.
+ * Modifications Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
  * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -62,7 +63,8 @@ public class PfTimestampKey extends PfKeyImpl {
      */
     public PfTimestampKey(@NonNull final PfTimestampKey copyConcept) {
         super(copyConcept);
-        this.timeStamp = new Date(copyConcept.getTimeStamp().getTime());
+        long millis = copyConcept.getTimeStamp().getTime();
+        this.timeStamp = new Date(millis);
     }
 
     /**