Skip to content

Commit

Permalink
feat : removed title from created post and add users name in create p…
Browse files Browse the repository at this point in the history
…ost query
  • Loading branch information
Pedrinvits committed Oct 18, 2024
1 parent 7354111 commit 049a00a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions data/createPost.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export const createpost = async (
include : {
author : {
select : {
name: true,
username : true,
profileImageUrl : true,
}
Expand Down
5 changes: 2 additions & 3 deletions src/components/create-post/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -132,19 +132,18 @@ const CreatePost = ({ posts, setPosts,onClose }: any) => {
<CardContent className="flex flex-col gap-4">
<Form {...form}>
<form onSubmit={form.handleSubmit(onSubmit)} className="space-y-8">
<FormField
{/* <FormField
control={form.control}
name="title"
render={({ field }) => (
<FormItem>
{/* <FormLabel>Title</FormLabel> */}
<FormControl>
<Input placeholder="Title" {...field} />
</FormControl>
<FormMessage />
</FormItem>
)}
/>
/> */}
<FormField
control={form.control}
name="description"
Expand Down

0 comments on commit 049a00a

Please sign in to comment.