-
Notifications
You must be signed in to change notification settings - Fork 0
[FEAT] 이미지 기능 재수정 #40
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
Changes from all commits
6ec4ea9
a38e531
f5a2450
7c97c16
fbbaeaa
eb922b2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,15 @@ | ||||||||||||||||||||||
| package team.wego.wegobackend.image.config; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| import lombok.Data; | ||||||||||||||||||||||
| import org.springframework.boot.context.properties.ConfigurationProperties; | ||||||||||||||||||||||
| import org.springframework.stereotype.Component; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| @Data | ||||||||||||||||||||||
|
Comment on lines
+3
to
+7
|
||||||||||||||||||||||
| import lombok.Data; | |
| import org.springframework.boot.context.properties.ConfigurationProperties; | |
| import org.springframework.stereotype.Component; | |
| @Data | |
| import lombok.Getter; | |
| import org.springframework.boot.context.properties.ConfigurationProperties; | |
| import org.springframework.stereotype.Component; | |
| @Getter |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,15 @@ | ||||||||||||||||||||||
| package team.wego.wegobackend.image.config; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| import lombok.Data; | ||||||||||||||||||||||
| import org.springframework.boot.context.properties.ConfigurationProperties; | ||||||||||||||||||||||
| import org.springframework.stereotype.Component; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| @Data | ||||||||||||||||||||||
|
Comment on lines
+3
to
+7
|
||||||||||||||||||||||
| import lombok.Data; | |
| import org.springframework.boot.context.properties.ConfigurationProperties; | |
| import org.springframework.stereotype.Component; | |
| @Data | |
| import lombok.Getter; | |
| import org.springframework.boot.context.properties.ConfigurationProperties; | |
| import org.springframework.stereotype.Component; | |
| @Getter |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,4 @@ | ||||||||||||||||||||||
| package team.wego.wegobackend.image.domain; | ||||||||||||||||||||||
|
|
||||||||||||||||||||||
| public record ImageSize(int width, int height) { | ||||||||||||||||||||||
|
||||||||||||||||||||||
| public record ImageSize(int width, int height) { | |
| public record ImageSize(int width, int height) { | |
| public ImageSize { | |
| if (width <= 0) { | |
| throw new IllegalArgumentException("Width must be positive, got: " + width); | |
| } | |
| if (height <= 0) { | |
| throw new IllegalArgumentException("Height must be positive, got: " + height); | |
| } | |
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The convertToWebpWithSize method lacks documentation explaining its behavior. Specifically, it should document that Thumbnails.size() maintains aspect ratio by default, which may not produce exact dimensions if the source image has a different aspect ratio. This could lead to unexpected results when precise dimensions are required.