{"record":{"id":"33d39d1e2dcfdc33","repo":"hcengineering/platform","slug":"not-implemented-33d39d","errorCode":null,"errorMessage":"Not implemented","messagePattern":"Not implemented","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"warning","filePath":"plugins/telegram-resources/src/components/Chat.svelte","lineNumber":142,"sourceCode":"      {\n        content: jsonToHTML(markupToJSON(message)),\n        status: 'new',\n        attachments\n      },\n      objectId\n    )\n\n    objectId = generateId()\n    loading = false\n  }\n\n  // function getName (message: TelegramMessage, accounts: IdMap<PersonAccount>): string {\n  //   return message.incoming ? object.name : accounts.get(message.modifiedBy as PersonId)?.name ?? ''\n  // }\n\n  async function share (): Promise<void> {\n    // TODO: FIXME\n    throw new Error('Not implemented')\n    // const selectedMessages = messages.filter((m) => selected.has(m._id as unknown as Ref<SharedTelegramMessage>))\n    // await client.addCollection(\n    //   telegram.class.SharedMessages,\n    //   object.space,\n    //   object._id,\n    //   object._class,\n    //   'sharedTelegramMessages',\n    //   {\n    //     messages: convertMessages(selectedMessages, $personAccountByIdStore)\n    //   }\n    // )\n    // if (channel !== undefined) {\n    //   await inboxClient.forceReadDoc(channel._id, channel._class)\n    // }\n    // clear()\n  }\n\n  function clear (): void {","sourceCodeStart":124,"sourceCodeEnd":160,"githubUrl":"https://github.com/hcengineering/platform/blob/63e28dc96483967b2fc21c881b3f1023c1de7718/plugins/telegram-resources/src/components/Chat.svelte#L124-L160","documentation":"The share() function in telegram-resources Chat.svelte is an unfinished feature: it immediately throws Error('Not implemented') with a TODO FIXME comment, and the original implementation body is commented out. Any user invoking the share action on a telegram chat hits this unconditionally — it is not a runtime failure but intentionally unshipped functionality.","triggerScenarios":"Clicking the share button / calling share() in the Telegram chat view — the function's first statement is the throw, so every invocation fails.","commonSituations":"User tries to share selected telegram messages to another chat; UI exposes an action whose backend (telegram.class.SharedMessages collection add) was disabled during a refactor.","solutions":["Hide or disable the share button in the UI until the feature is implemented.","Restore the commented-out implementation that filters selected messages and adds telegram.class.SharedMessages via client.addCollection.","If the underlying SharedMessages class was removed in a newer version, re-implement sharing against the current plugin API."],"exampleFix":"// before\nasync function share (): Promise<void> {\n  // TODO: FIXME\n  throw new Error('Not implemented')\n}\n// after\nasync function share (): Promise<void> {\n  const selectedMessages = messages.filter((m) => selected.has(m._id as unknown as Ref<SharedTelegramMessage>))\n  await client.addCollection(\n    telegram.class.SharedMessages,\n    object.space,\n    object._id,\n    object._class\n  )\n}","handlingStrategy":"fallback","validationCode":"// feature flag check before offering the action\nif (!isShareAvailable) hideShareButton()","typeGuard":null,"tryCatchPattern":"try {\n  await share()\n} catch (e) {\n  if (e.message === 'Not implemented') {\n    showNotification('Message sharing is not available yet')\n  } else throw e\n}","preventionTips":["Hide UI actions whose handlers throw Not implemented","Track unfinished features with feature flags","Restore the commented-out implementation before shipping the share button"],"tags":["not-implemented","unfinished-feature","ui"],"backgroundTag":"not-implemented","analyzedSha":"63e28dc96483967b2fc21c881b3f1023c1de7718","analyzedAt":"2026-08-29T15:21:27.377Z","schemaVersion":2},"datasetVersion":"2026-08-29T17:17:51.833Z"}