Skip to content

Commit 6c9ee4b

Browse files
committed
fixup!: use TSDoc for function docs
1 parent f28bd41 commit 6c9ee4b

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

lib/workers/repository/update/branch/auto-replace.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,17 @@ async function checkExistingBranch(
196196
return existingContent;
197197
}
198198

199-
// check if current !== newString and return 1 if it does or 0 if it doesn't
199+
/**
200+
* Check if an update from `current` to `newString` should be performed and return 1 if so.
201+
*
202+
* @remarks
203+
* Useful for counting the number of updates to do.
204+
*
205+
* @param {string|undefined} current The current value (if undefined then no update is required)
206+
* @param {string|undefined} newString The new value (if undefined then no update is required)
207+
*
208+
* @returns 1 if `current !== newString` and 0 if they are equal or at least one is undefined.
209+
*/
200210
function updatedToInt(
201211
current: string | undefined,
202212
newString: string | undefined,

0 commit comments

Comments
 (0)