Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Code Refactoring of Implementation and Design Smells in Alovoa without any conflicts #393

Closed
wants to merge 8 commits into from
Closed

Conversation

Poojitha1202
Copy link

@Poojitha1202 Poojitha1202 commented Apr 1, 2024

This PR comprises three code smell refactorings each at the implementation and design levels for alovoa.

Implementation Smell Refactoring 1:
Refactoring Technique Name : Extract method
Code Smell: Complex Method
Location :
Path: src/main/java
Package: alovoa/service
Class: RegisterService
Method: registerBase()

Implementation Smell Refactoring 2:
Refactoring Technique Name : Decompose Conditional
Code Smell: Complex Conditional
Location :
Path: src/main/java
Package: alovoa/service
Class: UserService
Method: hasNewMessage()

Implementation Smell Refactoring 3:
Refactoring Technique Name : Introducing Explaining Variable
Refactoring Technique Name: Magic Number
Location :
Path: src/main/java
Package: alovoa/model
Class: UserDto
Method: userToUserDto()

Design Smell Refactoring 1:
Refactoring Technique Name : Extract class
Code Smell: Insufficient modularization
Location :
Path: src/main/java
Package: alovoa/
Class: Tools
New Classes: CountryUtils and ValidationUtils
Dependency Classes Affected: service/MessageService and model/UserDto
Methods: getCountryEmoji() , isURLValid()

Design Smell Refactoring 2:
Refactoring Technique Name : Move Method
Code Smell: Feature Envy
Location :
Path: src/main/java
Package: alovoa/
Class: Tools
Class to which Method Moved : service/AuthService
Dependency Classes Affected : component/AuthSuccesshandler, rest/Oauth2Controller
Methods involved: getAuthParams()

Design Smell Refactoring 3:
Name : Pull Up Method & Extract Method
Code Smell: Insufficient Modularization
Location :
Path: src/main/java
Package: alovoa/service
Class: Tools
New Class: AgeUtils
Method: convertPrefAgeToRelativeYear(), convertPrefAgeToExactYear()

@Poojitha1202 Poojitha1202 closed this by deleting the head repository Jul 14, 2024
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.

1 participant