diff --git a/composer.json b/composer.json index 5da073a..15ede0d 100644 --- a/composer.json +++ b/composer.json @@ -7,7 +7,8 @@ "softonic/graphql-client": "^2.1", "symfony/console": "^5", "symfony/yaml": "^6.1", - "reload/jira-security-issue": "^2.0.11" + "reload/jira-security-issue": "^2.0.11", + "cweagans/composer-patches": "^1.7" }, "repositories": [ { @@ -32,5 +33,12 @@ "phpstan/extension-installer": true, "cweagans/composer-patches": true } + }, + "extra": { + "patches": { + "lesstif/php-jira-rest-client": { + "Update Jira API from v2 to v3": "patches/jira-api-v3.patch" + } + } } } diff --git a/patches/jira-api-v3.patch b/patches/jira-api-v3.patch new file mode 100644 index 0000000..92c8330 --- /dev/null +++ b/patches/jira-api-v3.patch @@ -0,0 +1,20 @@ +--- a/src/JiraClient.php ++++ b/src/JiraClient.php +@@ -66,7 +66,7 @@ class JiraClient + /** + * Json Mapper. + */ +- private string $api_uri = '/rest/api/2'; ++ private string $api_uri = '/rest/api/3'; + + /** + * JIRA REST API URI for webhooks. +@@ -222,7 +222,7 @@ class JiraClient + */ + public function setRestApiV2(): void + { +- $this->api_uri = '/rest/api/2'; ++ $this->api_uri = '/rest/api/3'; + } + + /**