Skip to content

Commit

Permalink
Fix: Null values are not supported
Browse files Browse the repository at this point in the history
  • Loading branch information
sswguo committed Jan 29, 2022
1 parent 1d93dfa commit 1fe60fb
Showing 1 changed file with 9 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -601,13 +601,16 @@ private ArtifactStore computeIfAbsent( String name, StoreKey key, int expiration
DtxArtifactStore dtxArtifactStore = storeQuery.getArtifactStore( key.getPackageType(), key.getType(), key.getName() );

store = toArtifactStore( dtxArtifactStore );
if ( expirationMins > 0 )
{
cache.put( key, store, expirationMins, TimeUnit.MINUTES );
}
else
if ( store != null )
{
cache.put( key, store );
if (expirationMins > 0)
{
cache.put(key, store, expirationMins, TimeUnit.MINUTES);
}
else
{
cache.put(key, store);
}
}
}

Expand Down

0 comments on commit 1fe60fb

Please sign in to comment.