Skip to content
This repository was archived by the owner on Oct 30, 2025. It is now read-only.

Commit 2f666f7

Browse files
committed
[REF] Removes unused code, gh_private_repo_token
1 parent 177ea0d commit 2f666f7

4 files changed

Lines changed: 0 additions & 33 deletions

File tree

client/src/components/CreateChannel/index.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
}
3030

3131
.install-github-app-link {
32-
/* text-transform: capitalize; */
3332
color: inherit;
3433
text-decoration: underline;
3534
}

client/src/components/MainLayout/index.js

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -8,36 +8,6 @@ import RightSidebar from "./../RightSidebar";
88
import "./index.css";
99

1010
export default function MainLayout(props) {
11-
useEffect(() => {
12-
const url = window.location.href;
13-
const hasCode = url.includes("?code=");
14-
15-
const proxy_url = `/api/auth/github/upgrade`;
16-
17-
// If Github API returns the code parameter
18-
if (hasCode) {
19-
const newUrl = url.split("?code=");
20-
21-
const requestData = {
22-
code: newUrl[1],
23-
};
24-
25-
fetch(proxy_url, {
26-
method: "POST",
27-
body: JSON.stringify(requestData),
28-
headers: {
29-
"Content-Type": "application/json",
30-
},
31-
})
32-
.then((response) => response.json())
33-
.then((data) => {
34-
Cookies.set("gh_private_repo_token", data.data.gh_private_repo_token);
35-
window.location.href =
36-
window.location.origin + Cookies.get("gh_upgrade_prev_path");
37-
})
38-
.catch((error) => console.log(error));
39-
}
40-
});
4111

4212
const {authState, stats} = props;
4313

client/src/components/RoomInfo/index.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ function a11yProps(index) {
5656
export default function RoomInfo(props) {
5757
const [repoInfo, setRepoInfo] = useState({});
5858
const [isPrivate, setIsPrivate] = useState(false);
59-
const [issuesCount] = useState(0);
6059
const [isNotAccessible, setIsNotAccessible] = useState(false);
6160
const [roomMembers, setRoomMembers] = useState([]);
6261
const [openMembersDialog, setOpenMembersDialog] = useState(false);

client/src/components/SignedLeftSidebar/index.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,6 @@ export default function SignedLeftSidebar(props) {
292292
Cookies.remove("rc_uid");
293293
Cookies.remove("rc_token");
294294
Cookies.remove("gh_login_token");
295-
Cookies.remove("gh_private_repo_token");
296295
window.location = "/login";
297296
})
298297
.catch((err) => {

0 commit comments

Comments
 (0)