Skip to content

Feature #87 implement request storage - #114

Open
gadirovakhadija wants to merge 3 commits into
mainfrom
feature_#87_implement_request_storage
Open

Feature #87 implement request storage#114
gadirovakhadija wants to merge 3 commits into
mainfrom
feature_#87_implement_request_storage

Conversation

@gadirovakhadija

Copy link
Copy Markdown
Contributor

I set setAuthentification method return UserDetails but in our we didn't need it. Beacause we need our UserDetails object return id and we will set in our dataStorage but UserDetails doesn't return id(it have only getPassword and getUsername). Because of that I create UserService and get user with getEmail and find id with similar method.

email
);

requestDataStorage.setUserId(userService.getByEmail(email).getId());

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

setAuthentication method already returns UserDetails. so you can use it for getting user id

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I saw your comment here.
as you know we have a class LoggedInUserDetails on the project (I can have a typo in the class name). So it includes id field as far as I know.
please try to use it

@gadirovakhadija gadirovakhadija Oct 20, 2023

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hamidsultanzadeh LoggedInUserDetails also doesn't have id field also. Can I set id field in LoggedInUSerDetails?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

then add it 😄

@hamidsultanzadeh hamidsultanzadeh linked an issue Oct 19, 2023 that may be closed by this pull request
void signUpOTPConfirmation(SignUpOTPRequest payload);

void setAuthentication(String email);
UserDetails setAuthentication(String email);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is that fine for the function with the "setAuthentication" name to return UserDetails and behave like getUserDetails?

Long userId;

String userLanguage;
String langId;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure the "langId" type should be String? Shouldn't we use Long instead of String?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE] Implement RequestStorage

3 participants