Commit 1d5a6f4
committed
Fix registerPush and unregisterPush Content-Type header
Set Content-Type to application/json for registerPush and unregisterPush
endpoints. Previously, contentTypeValue was set to nil, which caused the
Content-Type header to not be set at all. This resulted in PDS rejecting
requests with "Wrong request encoding" error.
The request body was already being JSON-encoded (via toJsonData()), but
without the Content-Type header, the server couldn't properly handle the
request.
Fixes the issue where push notification registration would fail with
400 Bad Request.1 parent f9b0cb8 commit 1d5a6f4
File tree
2 files changed
+2
-2
lines changed- Sources/ATProtoKit/APIReference/AppBskyAPI
2 files changed
+2
-2
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
| 66 | + | |
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
0 commit comments