Skip to content

Commit 39cff12

Browse files
authored
Change typoed function name in Params (#1284)
1 parent a1819e7 commit 39cff12

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Deprecate typoed function name lessThanorEqualTo (#1284)

src/params/types.ts

+9-1
Original file line numberDiff line numberDiff line change
@@ -297,10 +297,18 @@ export abstract class Param<T extends string | number | boolean | string[]> exte
297297
}
298298

299299
/** Returns a parametrized expression of Boolean type, based on comparing the value of this param to a literal or a different expression. */
300-
lessThanorEqualTo(rhs: T | Expression<T>) {
300+
lessThanOrEqualTo(rhs: T | Expression<T>) {
301301
return this.cmp("<=", rhs);
302302
}
303303

304+
/**
305+
* Returns a parametrized expression of Boolean type, based on comparing the value of this param to a literal or a different expression.
306+
* @deprecated A typo. Use lessThanOrEqualTo instead.
307+
*/
308+
lessThanorEqualTo(rhs: T | Expression<T>) {
309+
return this.lessThanOrEqualTo(rhs);
310+
}
311+
304312
toString(): string {
305313
return `params.${this.name}`;
306314
}

0 commit comments

Comments
 (0)