Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

Commit

Permalink
refactored using prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
sital002 committed Jun 8, 2024
1 parent a3c94bb commit bb85647
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions components/user/UserRepos.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import ArrowPathIcon from "@heroicons/react/24/outline/ArrowPathIcon";
import Button from "@components/Button";

export default function UserRepos({ manage = false, confirmDelete, repos }) {

const [reposList, setReposList] = useState(repos || []);
const [reorder, setReorder] = useState(false);
const [reposListPrevious, setReposListPrevious] = useState(repos || []);
Expand All @@ -32,13 +31,11 @@ export default function UserRepos({ manage = false, confirmDelete, repos }) {
setReorder(false);
};
useEffect(() => {
setReposList(repos)
setReposList(repos);
}, [repos]);


const item = (repo) => (
<div className="relative flex justify-between gap-x-6 px-4 py-5 hover:bg-primary-low dark:hover:bg-primary-medium transition-all duration-100 sm:px-6 lg:px-8">

<div className="flex gap-x-4">
<FallbackImage
className="h-12 w-12 flex-none rounded-full bg-primary-low"
Expand Down
2 changes: 1 addition & 1 deletion pages/api/account/manage/repos.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export async function updateReposOrderApi(username, data) {

const repos = await Promise.allSettled(repoList).then(() => {
return getReposApi(username);
})
});

return JSON.parse(JSON.stringify(repos));
}
Expand Down

0 comments on commit bb85647

Please sign in to comment.