Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mtxclient
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
mtxclient
Commits
d558041f
Unverified
Commit
d558041f
authored
1 year ago
by
Nicolas Werner
Committed by
GitHub
1 year ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #101 from ramajd/master
add default_payload to PusherData struct
parents
4f9709ec
b30d3545
Branches
reportContent
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#5622
failed
1 year ago
Stage: build
Stage: deploy
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
include/mtx/requests.hpp
+2
-4
2 additions, 4 deletions
include/mtx/requests.hpp
lib/structs/requests.cpp
+3
-0
3 additions, 0 deletions
lib/structs/requests.cpp
with
5 additions
and
4 deletions
include/mtx/requests.hpp
+
2
−
4
View file @
d558041f
...
...
@@ -10,11 +10,7 @@
#include
<mtx/events/collections.hpp>
#include
<mtx/identifiers.hpp>
#if __has_include(<nlohmann/json_fwd.hpp>)
#include
<nlohmann/json_fwd.hpp>
#else
#include
<nlohmann/json.hpp>
#endif
namespace
mtx
{
//! Namespace for request structs
...
...
@@ -408,6 +404,8 @@ struct PusherData
//! defined in the Push Gateway Specification. Currently the only format available is
//! 'event_id_only'.
std
::
string
format
;
//! Push gateway specific data.
std
::
optional
<
nlohmann
::
json
>
default_payload
;
friend
void
to_json
(
nlohmann
::
json
&
obj
,
const
PusherData
&
data
);
};
...
...
This diff is collapsed.
Click to expand it.
lib/structs/requests.cpp
+
3
−
0
View file @
d558041f
...
...
@@ -267,6 +267,9 @@ to_json(json &obj, const PusherData &data)
if
(
!
data
.
format
.
empty
())
{
obj
[
"format"
]
=
data
.
format
;
}
if
(
data
.
default_payload
)
{
obj
[
"default_payload"
]
=
data
.
default_payload
.
value
();
}
}
void
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment