Skip to content

Commit c274f4b

Browse files
committed
fix(flow): implement getStories method
The `getStories` method in the `GitLabIssue` and `GitHubIssue` classes was not implemented. This commit fixes the issue by implementing the method and returning an empty list.
1 parent 1e59e35 commit c274f4b

File tree

5 files changed

+3
-10
lines changed

5 files changed

+3
-10
lines changed

src/233/main/resources/META-INF/autodev-core.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,6 @@
253253
<add-to-group group-id="Vcs.Log.ChangesBrowser.Popup" relative-to-action="Vcs.RepositoryChangesBrowserMenu"
254254
anchor="after"/>
255255
<add-to-group group-id="Vcs.Log.ContextMenu" relative-to-action="Vcs.ShowDiffWithLocal" anchor="after"/>
256-
257-
<!-- Todo: spike when in Group -->
258256
</action>
259257

260258
<action id="autodev.Vcs.PrepushReview"

src/main/kotlin/cc/unitmesh/devti/context/base/NamedElementContext.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ import com.intellij.psi.PsiElement
44

55
abstract class NamedElementContext(open val root: PsiElement, open val text: String?, open val name: String?) :
66
LLMCodeContext {
7-
override fun format(): String = TODO()
7+
override fun format(): String = ""
88
}

src/main/kotlin/cc/unitmesh/devti/flow/kanban/impl/GitHubIssue.kt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,7 @@ class GitHubIssue(var repoUrl: String, val token: String) : Kanban {
3434
return SimpleProjectInfo(repo.fullName, repo.name, repo.description ?: "")
3535
}
3636

37-
override fun getStories(): List<SimpleStory> {
38-
TODO("Not yet implemented")
39-
}
37+
override fun getStories(): List<SimpleStory> = listOf()
4038

4139
override fun getStoryById(storyId: String): SimpleStory {
4240
val issue = gitHub.getRepository(repoUrl).getIssue(Integer.parseInt(storyId))

src/main/kotlin/cc/unitmesh/devti/flow/kanban/impl/GitLabIssue.kt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@ class GitLabIssue(private val apiUrl: String, private val personalAccessToken: S
2222
return SimpleProjectInfo(project.nameWithNamespace, project.name, project.description ?: "")
2323
}
2424

25-
override fun getStories(): List<SimpleStory> {
26-
TODO("Not yet implemented")
27-
}
25+
override fun getStories(): List<SimpleStory> = listOf()
2826

2927
override fun getStoryById(storyId: String): SimpleStory {
3028
val issue: Issue = gitLabApi.issuesApi.getIssue(apiUrl, storyId.toLong())

src/main/kotlin/cc/unitmesh/devti/intentions/AutoDevIntentionHelper.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ class AutoDevIntentionHelper : IntentionAction, Iconable {
3232
val popupStep = CustomPopupStep(intentions, project, editor, file, title)
3333
val popup = JBPopupFactory.getInstance().createListPopup(popupStep)
3434

35-
// TODO: after 2023.2 we can use this
3635
popup.showInBestPositionFor(editor)
3736
}
3837

0 commit comments

Comments
 (0)