Skip to content

Commit

Permalink
Adjust PlainTime valueOf implmentation
Browse files Browse the repository at this point in the history
  • Loading branch information
nekevss committed Dec 9, 2024
1 parent 029a62e commit a08d0e6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/engine/src/builtins/temporal/plain_time/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -580,9 +580,9 @@ impl PlainTime {
}

/// 4.3.22 Temporal.PlainTime.prototype.valueOf ( )
pub(crate) fn value_of(_this: &JsValue, _: &[JsValue], _: &mut Context) -> JsResult<JsValue> {
fn value_of(_this: &JsValue, _: &[JsValue], _: &mut Context) -> JsResult<JsValue> {
// 1. Throw a TypeError exception.
Err(JsNativeError::error()
Err(JsNativeError::typ()
.with_message("valueOf not implemented for Temporal objects. See 'compare', 'equals', or `toString`")
.into())
}
Expand Down

0 comments on commit a08d0e6

Please sign in to comment.