This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace Disposetest | |
{ | |
class test : IDisposable | |
{ | |
public void Dispose() | |
{ | |
Console.WriteLine("disposing"); | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Linq; | |
using System.Threading.Tasks; | |
using TWRC.Network; | |
using TWRC.Network.Handler; | |
using Dapper; | |
namespace TWRC.Game.Network.Handler | |
{ | |
public class JoinServer : HandlerBase<Client.VirtualClient> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ThrottlePlugin : IPlugin | |
{ | |
/// <param name="redisHost">host name</param> | |
/// <param name="redisPort">port</param> | |
/// <param name="redisPassword">password</param> | |
public ThrottlePlugin(string redisHost, int redisPort, string redisPassword = null) | |
{ | |
_redisClient = new RedisClient(redisHost, redisPort, redisPassword); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {AuthenticationError} from '../errors/authenticationError'; | |
export default (app) => { | |
app.use((error, request, response, next) => { | |
if (error || response.sentry) { // using Sentry in my specific case aswell | |
if (error instanceof AuthenticationError) { | |
response.statusCode = 401; | |
response.end( | |
JSON.stringify({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"openapi": "3.0.0", | |
"info": { | |
"title": "redacted", | |
"description": "The redacted API description", | |
"version": "1.0", | |
"contact": {} | |
}, | |
"tags": [], | |
"servers": [], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// spec can be found here: | |
// https://www.icao.int/publications/Documents/9303_p3_cons_en.pdf | |
// prettier-ignore | |
// noinspection NonAsciiCharacters | |
const transliterationMapping: Record<number, string|string[]> = { | |
0x0020: '<', | |
0x002C: '<', | |
0x002D: '<', | |
0x00C0: 'A', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const DEFAULT_ENGINE = 'davinci'; | |
export const ENGINE_LIST = ['ada', 'babbage', 'curie', 'davinci', 'davinci-instruct-beta', 'curie-instruct-beta']; | |
export const ORIGIN = 'https://api.openai.com'; | |
export const DEFAULT_API_VERSION = 'v1'; | |
export const DEFAULT_OPEN_AI_URL = `${ORIGIN}/${DEFAULT_API_VERSION}`; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { | |
ChangeEvent, | |
KeyboardEvent, | |
forwardRef, | |
HTMLAttributes, | |
InputHTMLAttributes, | |
useCallback, | |
useMemo, | |
useState, | |
FocusEvent, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use client'; | |
import { useEffect } from 'react'; | |
import type { NavigateOptions } from 'next/dist/shared/lib/app-router-context.shared-runtime'; | |
import { usePathname, useRouter } from 'next/navigation'; | |
import * as NProgress from 'nprogress'; | |
export function RouterPatch() { | |
const router = useRouter(); | |
const pathname = usePathname(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/node_modules/@hey-api/client-fetch/dist/index.cjs b/node_modules/@hey-api/client-fetch/dist/index.cjs | |
index 747c765..0dcebb4 100644 | |
--- a/node_modules/@hey-api/client-fetch/dist/index.cjs | |
+++ b/node_modules/@hey-api/client-fetch/dist/index.cjs | |
@@ -1,2 +1,2 @@ | |
-'use strict';var A=async(t,r)=>{let e=typeof r=="function"?await r(t):r;if(e)return t.scheme==="bearer"?`Bearer ${e}`:t.scheme==="basic"?`Basic ${btoa(e)}`:e},z=(t,r,e)=>{typeof e=="string"||e instanceof Blob?t.append(r,e):t.append(r,JSON.stringify(e));},j=(t,r,e)=>{typeof e=="string"?t.append(r,e):t.append(r,JSON.stringify(e));},$={bodySerializer:t=>{let r=new FormData;return Object.entries(t).forEach(([e,a])=>{a!=null&&(Array.isArray(a)?a.forEach(i=>z(r,e,i)):z(r,e,a));}),r}},b={bodySerializer:t=>JSON.stringify(t,(r,e)=>typeof e=="bigint"?e.toString():e)},k={bodySerializer:t=>{let r=new URLSearchParams;return Object.entries(t).forEach(([e,a])=>{a!=null&&(Array.isArray(a)?a.forEach(i=>j(r,e,i)):j(r,e,a));}),r.toString()}},U=t=>{switch(t){c |
OlderNewer