Skip to content

Commit

Permalink
Merge pull request #99 from HubSpot/feature/regenerationFixArchived
Browse files Browse the repository at this point in the history
Regeneration (fix archived)
  • Loading branch information
ksvirkou-hubspot authored Mar 10, 2022
2 parents cc8d318 + 115a8f0 commit 0ab37b0
Show file tree
Hide file tree
Showing 76 changed files with 1,025 additions and 1,025 deletions.
4 changes: 2 additions & 2 deletions codegen/Automation/Actions/Api/CallbacksApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ public function completeRequest($callback_id, $callback_completion_request)
$queryParams['hapikey'] = $apiKey;
}
// this endpoint requires OAuth (access token)
if ($this->config->getAccessToken() !== null) {
if (!empty($this->config->getAccessToken())) {
$headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();
}

Expand Down Expand Up @@ -592,7 +592,7 @@ public function completeBatchRequest($batch_input_callback_completion_batch_requ
$queryParams['hapikey'] = $apiKey;
}
// this endpoint requires OAuth (access token)
if ($this->config->getAccessToken() !== null) {
if (!empty($this->config->getAccessToken())) {
$headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();
}

Expand Down
16 changes: 8 additions & 8 deletions codegen/Automation/Actions/Api/DefinitionsApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -928,11 +928,11 @@ public function getByIdRequest($definition_id, $app_id, $archived = false)
if ($archived !== null) {
if('form' === 'form' && is_array($archived)) {
foreach($archived as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['archived'] = $archived;
$queryParams['archived'] = ObjectSerializer::toQueryValue($archived);
}
}

Expand Down Expand Up @@ -1258,33 +1258,33 @@ public function getPageRequest($app_id, $limit = null, $after = null, $archived
if ($limit !== null) {
if('form' === 'form' && is_array($limit)) {
foreach($limit as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['limit'] = $limit;
$queryParams['limit'] = ObjectSerializer::toQueryValue($limit);
}
}
// query params
if ($after !== null) {
if('form' === 'form' && is_array($after)) {
foreach($after as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['after'] = $after;
$queryParams['after'] = ObjectSerializer::toQueryValue($after);
}
}
// query params
if ($archived !== null) {
if('form' === 'form' && is_array($archived)) {
foreach($archived as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['archived'] = $archived;
$queryParams['archived'] = ObjectSerializer::toQueryValue($archived);
}
}

Expand Down
8 changes: 4 additions & 4 deletions codegen/Automation/Actions/Api/RevisionsApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -696,22 +696,22 @@ public function getPageRequest($definition_id, $app_id, $limit = null, $after =
if ($limit !== null) {
if('form' === 'form' && is_array($limit)) {
foreach($limit as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['limit'] = $limit;
$queryParams['limit'] = ObjectSerializer::toQueryValue($limit);
}
}
// query params
if ($after !== null) {
if('form' === 'form' && is_array($after)) {
foreach($after as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['after'] = $after;
$queryParams['after'] = ObjectSerializer::toQueryValue($after);
}
}

Expand Down
34 changes: 17 additions & 17 deletions codegen/Cms/AuditLogs/Api/AuditLogsApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -370,88 +370,88 @@ public function getPageRequest($object_id = null, $user_id = null, $after = null
if ($object_id !== null) {
if('form' === 'form' && is_array($object_id)) {
foreach($object_id as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['objectId'] = $object_id;
$queryParams['objectId'] = ObjectSerializer::toQueryValue($object_id);
}
}
// query params
if ($user_id !== null) {
if('form' === 'form' && is_array($user_id)) {
foreach($user_id as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['userId'] = $user_id;
$queryParams['userId'] = ObjectSerializer::toQueryValue($user_id);
}
}
// query params
if ($after !== null) {
if('form' === 'form' && is_array($after)) {
foreach($after as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['after'] = $after;
$queryParams['after'] = ObjectSerializer::toQueryValue($after);
}
}
// query params
if ($before !== null) {
if('form' === 'form' && is_array($before)) {
foreach($before as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['before'] = $before;
$queryParams['before'] = ObjectSerializer::toQueryValue($before);
}
}
// query params
if ($sort !== null) {
if('form' === 'form' && is_array($sort)) {
foreach($sort as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['sort'] = $sort;
$queryParams['sort'] = ObjectSerializer::toQueryValue($sort);
}
}
// query params
if ($event_type !== null) {
if('form' === 'form' && is_array($event_type)) {
foreach($event_type as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['eventType'] = $event_type;
$queryParams['eventType'] = ObjectSerializer::toQueryValue($event_type);
}
}
// query params
if ($limit !== null) {
if('form' === 'form' && is_array($limit)) {
foreach($limit as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['limit'] = $limit;
$queryParams['limit'] = ObjectSerializer::toQueryValue($limit);
}
}
// query params
if ($object_type !== null) {
if('form' === 'form' && is_array($object_type)) {
foreach($object_type as $key => $value) {
$queryParams[$key] = $value;
$queryParams[$key] = ObjectSerializer::toQueryValue($value);
}
}
else {
$queryParams['objectType'] = $object_type;
$queryParams['objectType'] = ObjectSerializer::toQueryValue($object_type);
}
}

Expand Down Expand Up @@ -500,7 +500,7 @@ public function getPageRequest($object_id = null, $user_id = null, $after = null
$queryParams['hapikey'] = $apiKey;
}
// this endpoint requires OAuth (access token)
if ($this->config->getAccessToken() !== null) {
if (!empty($this->config->getAccessToken())) {
$headers['Authorization'] = 'Bearer ' . $this->config->getAccessToken();
}

Expand Down
Loading

0 comments on commit 0ab37b0

Please sign in to comment.