Skip to content

Commit

Permalink
Addressing PR review comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnesky committed Sep 20, 2024
1 parent aa5ccf1 commit 3c9568a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 17 deletions.
17 changes: 4 additions & 13 deletions blocks/lists.ts
Original file line number Diff line number Diff line change
Expand Up @@ -417,10 +417,7 @@ const LISTS_GETINDEX = {
options: this.WHERE_OPTIONS,
}) as FieldDropdown;
menu.setValidator(
/**
* @param value The input value.
* @returns Null if the field has been replaced; otherwise undefined.
*/
/** @param value The input value. */
function (this: FieldDropdown, value: string) {
const oldValue: string | null = this.getValue();
const oldAt = oldValue === 'FROM_START' || oldValue === 'FROM_END';
Expand Down Expand Up @@ -645,10 +642,7 @@ const LISTS_SETINDEX = {
options: this.WHERE_OPTIONS,
}) as FieldDropdown;
menu.setValidator(
/**
* @param value The input value.
* @returns Null if the field has been replaced; otherwise undefined.
*/
/** @param value The input value. */
function (this: FieldDropdown, value: string) {
const oldValue: string | null = this.getValue();
const oldAt = oldValue === 'FROM_START' || oldValue === 'FROM_END';
Expand Down Expand Up @@ -816,11 +810,8 @@ const LISTS_GETSUBLIST = {
this[('WHERE_OPTIONS_' + n) as 'WHERE_OPTIONS_1' | 'WHERE_OPTIONS_2'],
}) as FieldDropdown;
menu.setValidator(
/**
* @param value The input value.
* @returns Null if the field has been replaced; otherwise undefined.
*/
function (this: FieldDropdown, value: string) {
/** @param value The input value. */
function (this: FieldDropdown, value: string) {
const oldValue: string | null = this.getValue();
const oldAt = oldValue === 'FROM_START' || oldValue === 'FROM_END';
const newAt = value === 'FROM_START' || value === 'FROM_END';
Expand Down
5 changes: 1 addition & 4 deletions blocks/text.ts
Original file line number Diff line number Diff line change
Expand Up @@ -223,10 +223,7 @@ const GET_SUBSTRING_BLOCK = {
this[('WHERE_OPTIONS_' + n) as 'WHERE_OPTIONS_1' | 'WHERE_OPTIONS_2'],
}) as FieldDropdown;
menu.setValidator(
/**
* @param value The input value.
* @returns Null if the field has been replaced; otherwise undefined.
*/
/** @param value The input value. */
function (this: FieldDropdown, value: any): null | undefined {
const oldValue: string | null = this.getValue();
const oldAt = oldValue === 'FROM_START' || oldValue === 'FROM_END';
Expand Down

0 comments on commit 3c9568a

Please sign in to comment.