Skip to content

Commit

Permalink
feat: ImageFile 정적 static method 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
shoeone96 committed Jan 19, 2024
1 parent 88c5d92 commit e83f62c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main/java/com/backendoori/ootw/image/dto/ImageFile.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
package com.backendoori.ootw.image.dto;

import com.backendoori.ootw.image.domain.Image;

public record ImageFile(
String url,
String fileName
) {

public static ImageFile from(Image image){
return new ImageFile(image.getImageUrl(), image.getFileName());
}
}

0 comments on commit e83f62c

Please sign in to comment.