Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
webhooks
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
webhooks
Commits
10a88f3b
Commit
10a88f3b
authored
4 years ago
by
Eric Sembrat
Committed by
Stefan Auditor
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3104635
by Surabhi Gokte, Webbeh: README.txt or README.md file is missing
parent
989d773f
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
README.md
+33
-0
33 additions, 0 deletions
README.md
Tests/Controller/WebhookTest.php
+0
-38
0 additions, 38 deletions
Tests/Controller/WebhookTest.php
invalid_events_trigger-2799511-2.patch
+0
-15
0 additions, 15 deletions
invalid_events_trigger-2799511-2.patch
with
33 additions
and
53 deletions
README.md
0 → 100644
+
33
−
0
View file @
10a88f3b
Webhooks
INTRODUCTION
------------
This module acts as both a Webhook dispatcher and receiver. For dispatching,
you can configure any amount of Webhooks that act on various events like entity
create, update, delete and others.
For receiving, the module captures the request and provides the payload to
others with a generic webhook event.
Configuration entity Webhook implementations are easily deployable.
REQUIREMENTS
------------
This module requires the following module:
*
Serialization (https://www.drupal.org/docs/8/core/modules/serialization)
INSTALLATION
------------
Install as you would normally install a contributed Drupal module.
For further information, visit:
https://www.drupal.org/docs/8/extending-drupal-8/installing-drupal-8-modules
CONFIGURATION
-------------
The module has no menu or modifiable settings. There is no configuration.
This diff is collapsed.
Click to expand it.
Tests/Controller/WebhookTest.php
deleted
100644 → 0
+
0
−
38
View file @
989d773f
<?php
namespace
Drupal\webhooks\Tests
;
use
Drupal\simpletest\WebTestBase
;
/**
* Provides automated tests for the webhooks module.
*/
class
WebhookTest
extends
WebTestBase
{
/**
* {@inheritdoc}
*/
public
static
function
getInfo
()
{
return
array
(
'name'
=>
"webhooks Webhook's controller functionality"
,
'description'
=>
'Test Unit for module webhooks and controller Webhook.'
,
'group'
=>
'Other'
,
);
}
/**
* {@inheritdoc}
*/
public
function
setUp
()
{
parent
::
setUp
();
}
/**
* Tests webhooks functionality.
*/
public
function
testWebhook
()
{
// Check that the basic functions of module webhooks.
$this
->
assertEquals
(
TRUE
,
TRUE
,
'Test Unit Generated via Drupal Console.'
);
}
}
This diff is collapsed.
Click to expand it.
invalid_events_trigger-2799511-2.patch
deleted
100644 → 0
+
0
−
15
View file @
989d773f
diff --git a/src/Entity/WebhookConfig.php b/src/Entity/WebhookConfig.php
index 2e28514..659d808 100644
--- a/src/Entity/WebhookConfig.php
+++ b/src/Entity/WebhookConfig.php
@@ -243,7 +243,9 @@
class WebhookConfig extends ConfigEntityBase implements WebhookConfigInterface {
*/
public function preSave(EntityStorageInterface $storage) {
parent::preSave($storage);
- $this->events = serialize($this->events);
+ $this->events = serialize(
+ array_filter($this->events)
+ );
}
}
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