Skip to content

Commit

Permalink
removed old comments
Browse files Browse the repository at this point in the history
  • Loading branch information
sinamics committed Apr 8, 2023
1 parent 5fd63e8 commit c2cdf76
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 64 deletions.
3 changes: 2 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@
"Prisma.prisma",
"bradlc.vscode-tailwindcss",
"austenc.tailwind-docs",
"bourhaouta.tailwindshades"
"bourhaouta.tailwindshades",
"Gruntfuggly.todo-tree"
]
}
}
Expand Down
27 changes: 0 additions & 27 deletions src/components/protectedPageRoute.ts

This file was deleted.

9 changes: 0 additions & 9 deletions src/server/api/networkService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,9 @@
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
/* eslint-disable @typescript-eslint/no-unsafe-argument */

// import { PubSub } from "apollo-server-express";

import * as ztController from "~/utils/ztApi";
import { prisma } from "../db";

// const arrOfNetworks = new Set();
// let timeout: ReturnType<typeof setTimeout>;

// Fetch data for online users and push them via wesocket.
// TODO i user has two tabs open on the same page, this logic will break, or data will not be pushed if one tab is closed.

// This function checks if the given IP address is likely a private IP address
function isPrivateIP(ip: string): boolean {
const ipInt = ip
Expand Down Expand Up @@ -70,7 +62,6 @@ export const updateNetworkMembers = async (zt_controller: any) => {
if (zt_controller.members.length === 0) return;

// Get peers to view online status members

for (const member of zt_controller.members) {
member.peers = (await ztController.peer(member.address)) || null;
member.creationTime = member.creationTime / 1000;
Expand Down
28 changes: 1 addition & 27 deletions src/server/api/routers/authRouter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ export const authRouter = createTRPCRouter({

const hash = bcrypt.hashSync(password, 10);

// Send validation link to user by mail
// TODO send validation link to user by mail
// sendMailValidationLink(i);

// Check the total number of users in the database
Expand All @@ -118,32 +118,6 @@ export const authRouter = createTRPCRouter({
return {
user: newUser,
};

// Generate ipv4 address, cidr, start & end
// const ipAssignmentPools = Ip4.randomIPv4();
// const networkName = process.env.ZT_DEFAULT_NETWORKNAME;
// // Create ZT network
// await ztn
// .network_create(networkName, ipAssignmentPools)
// .then(async (newNw) => {
// // store the created User in db
// return await AuthService.users.update({
// where: {
// userid: newuser.userid,
// },
// data: {
// network: {
// create: {
// nwname: newNw.name,
// nwid: newNw.nwid,
// },
// },
// },
// select: {
// network: true,
// },
// });
// });
}),
me: protectedProcedure.query(async ({ ctx }) => {
await ctx.prisma.user.findFirst({
Expand Down

0 comments on commit c2cdf76

Please sign in to comment.