refactor: add max func to maxTimestamp

Signed-off-by: komisan19 <18901496+komisan19@users.noreply.github.com>
This commit is contained in:
komisan19 2024-04-21 23:31:50 +09:00
parent 8cd7e04fd2
commit 5ab24a06d0
1 changed files with 2 additions and 4 deletions

View File

@ -442,10 +442,8 @@ func mostRecentTimestampInMetric(metric pmetric.Metric) pcommon.Timestamp {
}
func maxTimestamp(a, b pcommon.Timestamp) pcommon.Timestamp {
if a > b {
return a
}
return b
resultTimestamp := max(a, b)
return resultTimestamp
}
// addSingleSummaryDataPoint converts pt to len(QuantileValues) + 2 samples.