Skip to content

Commit 104d4df

Browse files
authored
Merge pull request #894 from luhn/lastcall-undefined
Change `lastCall` return type to `CallLog | undefined`
2 parents 8a8e894 + 217f877 commit 104d4df

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/fetch-mock/src/CallHistory.ts

+4-1
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,10 @@ class CallHistory {
127127
called(filter?: CallHistoryFilter, options?: RouteConfig): boolean {
128128
return Boolean(this.calls(filter, options).length);
129129
}
130-
lastCall(filter?: CallHistoryFilter, options?: RouteConfig): CallLog | void {
130+
lastCall(
131+
filter?: CallHistoryFilter,
132+
options?: RouteConfig,
133+
): CallLog | undefined {
131134
return this.calls(filter, options).pop();
132135
}
133136

0 commit comments

Comments
 (0)