Skip to content

Commit 8ab6ef4

Browse files
committed
Update CHANGELOG.md and apply lints
1 parent 5cf1fbf commit 8ab6ef4

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.17.0...main)
44

5-
* [#542](https://github.com/mozilla/glean.js/pull/542): Implement `shutdown` API.
5+
* [#542](https://github.com/mozilla/glean.js/pull/542), [#552](https://github.com/mozilla/glean.js/pull/552): Implement `shutdown` API.
66

77
# v0.17.0 (2021-07-16)
88

glean/src/core/upload/index.ts

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,8 @@ class PingUploader implements PingsDatabaseObserver {
129129

130130
// If the ping is a deletion-request ping, we want to enqueue it as a persistent task,
131131
// so that clearing the queue does not clear it.
132-
let launchFn = isDeletionRequest(ping)
133-
? this.dispatcher.launchPersistent
134-
: this.dispatcher.launch;
132+
// eslint-disable-next-line @typescript-eslint/unbound-method
133+
const launchFn = isDeletionRequest(ping) ? this.dispatcher.launchPersistent : this.dispatcher.launch;
135134

136135
// Dispatch the uploading task.
137136
launchFn.bind(this.dispatcher)(async (): Promise<void> => {
@@ -238,7 +237,14 @@ class PingUploader implements PingsDatabaseObserver {
238237
finalPing.headers
239238
);
240239
} catch(e) {
241-
log(LOG_TAG, ["Error trying to build ping request:", e.message], LoggingLevel.Warn);
240+
log(
241+
LOG_TAG,
242+
[
243+
"Error trying to build ping request:",
244+
(e as Error).message
245+
],
246+
LoggingLevel.Warn
247+
);
242248
// An unrecoverable failure will make sure the offending ping is removed from the queue and
243249
// deleted from the database, which is what we want here.
244250
return {

glean/tests/unit/core/upload/index.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ describe("PingUploader", function() {
7575

7676
it("clearing does not clear deletion-request ping job", async function () {
7777
const httpClient = new WaitableUploader();
78-
const postSpy = sandbox.spy(httpClient, "post")
78+
const postSpy = sandbox.spy(httpClient, "post");
7979
await Glean.testResetGlean(testAppId, true, { httpClient });
8080

8181

0 commit comments

Comments
 (0)