Skip to content

Commit c72f49e

Browse files
committed
fix(ecmascript): fix merge error
1 parent f6475e1 commit c72f49e

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

crates/oxc_ecmascript/src/constant_evaluation/call_expr.rs

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,12 @@ fn try_fold_url_related_function<'a>(
3131
ctx: &impl ConstantEvaluationCtx<'a>,
3232
) -> Option<ConstantValue<'a>> {
3333
match ident.name.as_str() {
34-
"encodeURI" if ctx.is_global_reference(ident) == Some(true) => {
35-
try_fold_encode_uri(arguments, ctx)
36-
}
37-
"encodeURIComponent" if ctx.is_global_reference(ident) == Some(true) => {
34+
"encodeURI" if ctx.is_global_reference(ident) => try_fold_encode_uri(arguments, ctx),
35+
"encodeURIComponent" if ctx.is_global_reference(ident) => {
3836
try_fold_encode_uri_component(arguments, ctx)
3937
}
40-
"decodeURI" if ctx.is_global_reference(ident) == Some(true) => {
41-
try_fold_decode_uri(arguments, ctx)
42-
}
43-
"decodeURIComponent" if ctx.is_global_reference(ident) == Some(true) => {
38+
"decodeURI" if ctx.is_global_reference(ident) => try_fold_decode_uri(arguments, ctx),
39+
"decodeURIComponent" if ctx.is_global_reference(ident) => {
4440
try_fold_decode_uri_component(arguments, ctx)
4541
}
4642
_ => None,

0 commit comments

Comments
 (0)