Skip to content

Commit

Permalink
Code cleanup up to SPBAuthenticator
Browse files Browse the repository at this point in the history
  • Loading branch information
Antonia Heinen committed Jul 12, 2024
1 parent e3326dd commit 1dff006
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 23 deletions.
2 changes: 1 addition & 1 deletion Squello-Core.package/SPBAssignee.class/instance/hash.st
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
comparing
hash

"Answer an integer value that is related to the identity of the receiver."

^ self id hash.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"=" : "LW 7/14/2022 12:24",
"asJson" : "FP 6/25/2024 11:13",
"asString" : "lo 5/28/2022 12:17",
"hash" : "LW 7/14/2022 11:23",
"hash" : "AH 7/12/2024 15:44",
"id" : "lo 5/16/2022 22:43",
"id:" : "tk 8/2/2022 23:42",
"isAssignee" : "lo 8/1/2022 14:48",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ actionSubmit

| oldUsername areCredentialsNil |
areCredentialsNil := (self username isNil or: [self token isNil]).
areCredentialsNil ifTrue: [^ self errorEmptyField].
areCredentialsNil
ifTrue: [^ self errorEmptyField].

SPBAuthenticator token: self token.
oldUsername := SPBAuthenticator username.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ toolbuilder
buildWith: aBuilder

^ aBuilder build: (aBuilder pluggableDialogSpec new
model: self;
label: #labelString;
extent: 600@60;
exclusive: false;
message: 'Insert GitHub authentication data:';
children: {self buildInputPanel: aBuilder};
buttons: (self buildButtons: aBuilder);
yourself).
model: self;
label: #labelString;
extent: 600 @ 60;
exclusive: false;
message: 'Insert GitHub authentication data:';
children: {self buildInputPanel: aBuilder};
buttons: (self buildButtons: aBuilder);
yourself).
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
accessing
token

^ token ifNil: [token := SPBAuthenticator token].
^ token
ifNil: [token := SPBAuthenticator token].
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
accessing
username

^ username ifNil: [username := SPBAuthenticator username].
^ username
ifNil: [username := SPBAuthenticator username].
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@
"open" : "jh 7/31/2022 13:05" },
"instance" : {
"actionCancel" : "mcr 7/4/2022 00:36",
"actionSubmit" : "FP 7/12/2024 12:58",
"actionSubmit" : "AH 7/12/2024 15:44",
"buildButtons:" : "FP 6/13/2024 11:10",
"buildInputFields:" : "mcr 8/4/2022 00:18",
"buildInputPanel:" : "tk 8/2/2022 23:42",
"buildWith:" : "tk 8/2/2022 23:43",
"buildWith:" : "AH 7/12/2024 15:45",
"checkUserValid" : "lo 7/13/2022 19:16",
"close" : "lo 8/1/2022 14:16",
"errorEmptyField" : "mcr 8/4/2022 00:36",
"errorUserNotFound" : "mcr 8/4/2022 00:36",
"labelString" : "lo 7/13/2022 19:29",
"resetCredentials" : "FP 7/12/2024 12:58",
"token" : "FP 7/12/2024 13:04",
"token" : "AH 7/12/2024 15:45",
"token:" : "lo 7/13/2022 19:26",
"updateToken:" : "mcr 8/4/2022 00:18",
"updateUsername:" : "mcr 8/4/2022 00:18",
"username" : "FP 7/12/2024 12:57",
"username" : "AH 7/12/2024 15:45",
"username:" : "lo 7/13/2022 19:27" } }
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,4 @@ authenticate
self checkIfCredentialsMissing
ifTrue: [SPBAuthenticationForm open].
self checkIfCredentialsMissing
ifTrue: [self errorAuthenticationCanceled. Error signal].

"this is now handled by the boardProvider"
"[self checkIfTokenValid]
on: Error do: [Error signal]."
ifTrue: [self errorAuthenticationCanceled. Error signal].
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"username" : "FP 7/12/2024 12:50",
"username:" : "FP 7/12/2024 12:50" },
"instance" : {
"authenticate" : "FP 7/12/2024 12:55",
"authenticate" : "AH 7/12/2024 15:46",
"boardProvider" : "mcr 8/2/2022 18:26",
"boardProvider:" : "mcr 8/2/2022 18:26",
"checkIfCredentialsMissing" : "FP 7/12/2024 12:56",
Expand Down

0 comments on commit 1dff006

Please sign in to comment.