Skip to content

Commit 40dc42b

Browse files
committed
DEV: Drop unused code
1 parent 9ece0b8 commit 40dc42b

1 file changed

Lines changed: 2 additions & 15 deletions

File tree

assets/javascripts/discourse/components/docs-topic.gjs

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,18 @@
11
/* eslint-disable ember/no-classic-components, ember/require-tagless-components */
22
import Component from "@ember/component";
33
import { computed } from "@ember/object";
4-
import { reads } from "@ember/object/computed";
5-
import { service } from "@ember/service";
6-
import { htmlSafe } from "@ember/template";
74
import { classNames } from "@ember-decorators/component";
85
import DButton from "discourse/components/d-button";
96
import PluginOutlet from "discourse/components/plugin-outlet";
107
import Post from "discourse/components/post";
118
import icon from "discourse/helpers/d-icon";
9+
import trustHTML from "discourse/helpers/trust-html";
1210
import discourseDebounce from "discourse/lib/debounce";
1311
import { bind } from "discourse/lib/decorators";
14-
import transformPost from "discourse/lib/transform-post";
1512
import { i18n } from "discourse-i18n";
1613

1714
@classNames("docs-topic")
1815
export default class DocsTopic extends Component {
19-
@service currentUser;
20-
@service site;
21-
22-
@reads("post.cooked") originalPostContent;
23-
24-
@computed("currentUser", "model")
25-
get post() {
26-
return transformPost(this.currentUser, this.site, this.model);
27-
}
28-
2916
@computed("topic", "topic.post_stream")
3017
get model() {
3118
const post = this.store.createRecord(
@@ -72,7 +59,7 @@ export default class DocsTopic extends Component {
7259
/>
7360

7461
<div class="topic-content">
75-
<h1>{{htmlSafe this.topic.fancyTitle}}</h1>
62+
<h1>{{trustHTML this.topic.fancyTitle}}</h1>
7663
<Post @post={{this.model}} />
7764
</div>
7865

0 commit comments

Comments
 (0)