Skip to content

Commit

Permalink
resolve linting violations
Browse files Browse the repository at this point in the history
  • Loading branch information
ramonvermeulen committed Aug 5, 2024
1 parent f69181c commit 41252cd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package com.github.ramonvermeulen.dbtToolkit.services
import com.intellij.execution.ui.ConsoleViewContentType
import com.intellij.openapi.components.Service
import com.intellij.openapi.components.service
import com.intellij.openapi.project.DumbService
import com.intellij.openapi.project.Project
import com.intellij.openapi.projectRoots.Sdk
import com.intellij.openapi.roots.ProjectRootManager
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import com.github.ramonvermeulen.dbtToolkit.ui.IdeaPanel
import com.intellij.openapi.Disposable
import com.intellij.openapi.application.ApplicationManager
import com.intellij.openapi.components.service
import com.intellij.openapi.editor.Document
import com.intellij.openapi.editor.EditorFactory
import com.intellij.openapi.fileEditor.FileDocumentManager
import com.intellij.openapi.fileEditor.FileEditorManager
Expand Down Expand Up @@ -84,7 +83,7 @@ class CompiledSqlPanel(project: Project) : IdeaPanel, Disposable, ActiveFileList

private fun findCompiledFile(file: VirtualFile): VirtualFile? {
return file.let { nonNullFile ->
settings.state.dbtModelPaths.map { Regex("${it}.*").find(nonNullFile.path)?.value }
settings.state.dbtModelPaths.map { Regex("$it.*").find(nonNullFile.path)?.value }
.firstOrNull { it != null }
?.let { relativePath ->
val targetPath = Paths.get(settings.state.dbtTargetDir, "compiled", settings.state.dbtProjectName, relativePath)
Expand Down

0 comments on commit 41252cd

Please sign in to comment.