summaryrefslogtreecommitdiff
path: root/packages/backend/src/services/chart (follow)
Commit message (Collapse)AuthorAgeFilesLines
* なんかもうめっちゃ変えたsyuilo2022-09-1835-1751/+0
|
* fix(test): make chart tests workingsyuilo2022-06-051-0/+12
|
* refactor: improve code quality (#8751)Johann1502022-05-291-17/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * remove unnecessary if `Array.prototype.some` already returns a boolean so an if to return true or false is completely unnecessary in this case. * perf: use count instead of find When using `count` instead of `findOneBy`, the data is not unnecessarily loaded. * remove duplicate null check The variable is checked for null in the lines above and the function returns if so. Therefore, it can not be null at this point. * simplify `getJsonSchema` Because the assigned value is `null` and the used keys are only shallow, use of `nestedProperty.set` seems inappropriate. Because the value is not read, the initial for loop can be replaced by a `for..in` loop. Since all keys will be assigned `null`, the condition of the ternary expression in the nested function will always be true. Therefore the recursion case will never happen. With this the nested function can be eliminated. * remove duplicate condition The code above already checks `dragging` and returns if it is truthy. Checking it again later is therefore unnecessary. To make this more obvious the `return` is removed in favour of using an if...else construct. * remove impossible "unknown" time The `ago` variable will always be a number and all non-negative numbers are already covered by other cases, the negative case is handled with `future` so there is no case when `unkown` could be achieved.
* refactor: migrate to typeorm 3.0 (#8443)syuilo2022-03-267-30/+34
| | | | | | | | | | | | | | | | | | | | | | | * wip * wip * wip * Update following.ts * wip * wip * wip * Update resolve-user.ts * maxQueryExecutionTime * wip * wip
* fix federation chartsyuilo2022-03-082-9/+29
|
* delete needless instance drive columnssyuilo2022-03-071-2/+0
|
* feat: add active to federation chartsyuilo2022-03-072-1/+9
|
* fix query errorsyuilo2022-03-041-3/+3
|
* enhance(chart): better federation pub/sub calculationsyuilo2022-03-041-1/+14
|
* fix federation chart pubsubsyuilo2022-03-041-1/+1
|
* refactor: Use ESM (#8358)syuilo2022-02-2735-194/+101
| | | | | | | | | | | | | | | * wip * wip * fix * clean up * Update tsconfig.json * Update activitypub.ts * wip
* feat: add pub & sub item for federation chartsyuilo2022-02-232-1/+14
|
* refactor: use ajv instead of cafy (#8324)syuilo2022-02-191-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * wip * wip * Update abuse-user-reports.ts * Update files.ts * Update list-remote.ts * Update list.ts * Update show-users.ts * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * Update update.ts * Update search.ts * Update reactions.ts * Update search.ts * wip * wip * wip * wip * Update update.ts * Update relation.ts * Update available.ts * wip * wip * wip * Update packages/backend/src/server/api/define.ts Co-authored-by: Johann150 <johann.galle@protonmail.com> * Update define.ts * Update define.ts * typo * wip * wip * wip * wip * wip * wip * wip * wip * Update update.ts * wip * Update signup.ts * Update call.ts * minimum for limit * type * remove needless annotation * wip * Update signup.ts * wip * wip * fix * Update create.ts Co-authored-by: Johann150 <johann.galle@protonmail.com>
* refactor: better getChart result typesyuilo2022-02-181-2/+14
|
* refactor: fix typessyuilo2022-02-131-4/+4
|
* refactor: fix typessyuilo2022-02-131-63/+72
|
* enhance: improve federation chartsyuilo2022-02-1018-34/+128
|
* fix(server): ↵syuilo2022-02-091-0/+4
| | | | チャートのcleanでエラーが出る可能性がある問題を修正
* fix(server): チャートのresyncでエラーが出る問題を修正syuilo2022-02-091-0/+4
| | | | Fix #8274
* feat: introduce intersection calculation of chartssyuilo2022-02-095-6/+79
|
* feat: improve federation chartsyuilo2022-02-082-2/+5
|
* feat: ↵syuilo2022-02-086-0/+7
| | | | notes/instance/perUserNotesチャートに添付ファイル付きノートの数を追加
* chore: remove unused codesyuilo2022-02-081-10/+0
|
* fixsyuilo2022-02-061-11/+11
|
* imprpve active users chartsyuilo2022-02-062-5/+27
|
* fix chart cleansyuilo2022-02-061-2/+2
|
* Improve chart engine (#8253)syuilo2022-02-0635-1650/+525
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * wip * wip * wip * wip * wip * wip * wip * Update core.ts * wip * wip * #7361 * delete network chart * federationChart強化 apRequestChart追加 * tweak
* refactor: ↵tamaina2022-01-181-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | APIエンドポイントファイルの定義を良い感じにする (#8154) * Fix API Schema Error * Delete SimpleSchema/SimpleObj and Move schemas to dedicated files * Userのスキーマを分割してみる * define packMany type * add , * Ensure enum schema and Make "as const" put once * test? * Revert "test?" This reverts commit 97dc9bfa70851bfb7d1cf38e883f8df20fb78b79. * Revert "Fix API Schema Error" This reverts commit 21b6176d974ed8e3eb73723ad21a105c5d297323. * :v: * clean up * test? * wip * wip * better schema def * :v: * fix * add minLength property * wip * wip * wip * anyOf/oneOf/allOfに対応? ~ relation.ts * refactor! * Define MinimumSchema * wip * wip * anyOf/oneOf/allOfが動作するようにUnionSchemaTypeを修正 * anyOf/oneOf/allOfが動作するようにUnionSchemaTypeを修正 * Update packages/backend/src/misc/schema.ts Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com> * fix * array oneOfをより正確な型に * array oneOfをより正確な型に * wip * :v: * なんかもういろいろ * remove * very good schema * api schema * wip * refactor: awaitAllの型定義を変えてみる * fix * specify types in awaitAll * specify types in awaitAll * :v: * wip * ... * :v: * AllowDateはやめておく * 不必要なoptional: false, nullable: falseを廃止 * Packedが展開されないように * 続packed * wip * define note type * wip * UserDetailedをMeDetailedかUserDetailedNotMeかを区別できるように * wip * wip * wip specify user type of other schemas * ok * convertSchemaToOpenApiSchemaを改修 * convertSchemaToOpenApiSchemaを改修 * Fix * fix * :v: * wip * 分割代入ではなくallOfで定義するように Co-authored-by: Acid Chicken (硫酸鶏) <root@acid-chicken.com>
* enhance(backend): improve chart enginesyuilo2021-12-1433-234/+376
|
* fix lintsyuilo2021-12-0932-117/+117
|
* fix lint errorssyuilo2021-11-121-8/+8
|
* refactoringsyuilo2021-11-1233-0/+2516
Resolve #7779