feat: fix wrong message Unauthorized to connect to Openproject#1018
Draft
Ashim-Stha wants to merge 1 commit into
Draft
feat: fix wrong message Unauthorized to connect to Openproject#1018Ashim-Stha wants to merge 1 commit into
Ashim-Stha wants to merge 1 commit into
Conversation
saw-jan
reviewed
May 11, 2026
b8f4510 to
7c574a1
Compare
saw-jan
reviewed
May 12, 2026
9276eb7 to
d6f2af2
Compare
Signed-off-by: Ashim Shrestha <ashimshrestha2384@gmail.com>
d6f2af2 to
e40c145
Compare
saw-jan
reviewed
May 14, 2026
Comment on lines
1756
to
1759
| if ($token) { | ||
| $this->logger->debug('Token has expired.', ['app' => $this->appName]); | ||
| $this->logger->debug('Refreshing access token.', ['app' => $this->appName]); | ||
| } |
Collaborator
There was a problem hiding this comment.
clear user_name and user_id here
saw-jan
reviewed
May 14, 2026
| public function initUserInfo(string $userId, string $accessToken): array { | ||
| $savedUserId = $this->config->getUserValue($userId, Application::APP_ID, 'user_id'); | ||
| $savedUsername = $this->config->getUserValue($userId, Application::APP_ID, 'user_name'); | ||
| if (!$savedUserId || !$savedUsername) { |
Collaborator
There was a problem hiding this comment.
Suggested change
| if (!$savedUserId || !$savedUsername) { | |
| if ($savedUserId && $savedUsername) { | |
| return; | |
| } |
saw-jan
reviewed
May 14, 2026
| $response = $this->rawRequest($accessToken, $openprojectUrl, '/users/me'); | ||
| $info = json_decode($response->getBody(), true); | ||
| } catch (Exception $e) { | ||
| $this->logger->error('OpenProject error : ' . $e->getMessage()); |
Collaborator
There was a problem hiding this comment.
Suggested change
| $this->logger->error('OpenProject error : ' . $e->getMessage()); | |
| $this->logger->error('OpenProject error : ' . $e->getMessage(), ['app' => $this->appName]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Related Issue or Workpackage
Screenshots (if appropriate):
Types of changes
Checklist:
CHANGELOG.mdfile