Skip to content

Commit 9b1818e

Browse files
authored
refactor: wow nick, wow (#29)
1 parent e69e508 commit 9b1818e

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed

src/utils/fileContents.js

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@ const fileContents = (
55
postIdStr,
66
postType,
77
postAuthor
8-
) => `{
9-
"postId": "${postIdStr}",
10-
"titleContent": "${postTitle}",
11-
"textContent": ${postText},
12-
"imageSource": "${postImage}",
13-
"createdAt": ${Date.now()},
14-
"postType": "${postType}",
15-
"postAuthor": "${postAuthor}"
16-
}`;
8+
) =>
9+
JSON.stringify({
10+
postId: postIdStr,
11+
titleContent: postTitle,
12+
textContent: postText,
13+
imageSource: postImage,
14+
createdAt: Date.now(),
15+
postType: postType,
16+
postAuthor: postAuthor
17+
});
1718

1819
export default fileContents;
1920

0 commit comments

Comments
 (0)