Refine method comments in humidity.go

Comments for DateTime and Value methods in humidity.go file were updated to better describe their functionalities. This clarification should improve understandability for future maintenance/code reading.
This commit is contained in:
Winni Neessen 2023-06-27 18:49:32 +02:00
parent 65d065dd59
commit 84ba2feda9
Signed by: wneessen
GPG key ID: 5F3AF39B820C119D

View file

@ -20,8 +20,8 @@ func (h Humidity) IsAvailable() bool {
return !h.na
}
// DateTime returns true if an Humidity value was
// available at time of query
// DateTime returns the timestamp of when the humidity
// measurement was taken.
func (h Humidity) DateTime() time.Time {
return h.dt
}
@ -39,7 +39,7 @@ func (h Humidity) Source() Source {
// Value returns the float64 value of an Humidity
// If the Humidity is not available in the WeatherData
// Vaule will return math.NaN instead.
// Value will return math.NaN instead.
func (h Humidity) Value() float64 {
if h.na {
return math.NaN()