Skip to content

Commit

Permalink
address comment for handling single data
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-dydx committed Oct 23, 2024
1 parent 084b5b3 commit 8d23592
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,8 @@ internal class VaultSupervisor(
val dailyResponse = deferredDaily.await()
val hourlyResponse = deferredHourly.await()

if (dailyResponse.response != null && hourlyResponse.response != null) {
stateMachine.onMegaVaultPnl(listOf(dailyResponse.response, hourlyResponse.response))
if (dailyResponse.response != null || hourlyResponse.response != null) {
stateMachine.onMegaVaultPnl(listOfNotNull(dailyResponse.response, hourlyResponse.response))
} else if (dailyResponse.error != null) {
Logger.e {
"Failed to retrieve day mega vault pnl: ${dailyResponse.error}"
Expand Down

0 comments on commit 8d23592

Please sign in to comment.