Skip to content

Commit cf038da

Browse files
committed
fix non-extendable methods usage violations
1 parent 73684db commit cf038da

File tree

4 files changed

+8
-19
lines changed

4 files changed

+8
-19
lines changed

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ plugins {
77
}
88

99
group = 'lechuck'
10-
version = '1.7.0'
10+
version = '1.7.1'
1111

1212
java {
1313
sourceCompatibility = JavaVersion.VERSION_17
Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
11
package lechuck.intellij
22

33
import com.intellij.openapi.fileChooser.FileChooserDescriptor
4-
import com.intellij.openapi.vfs.VirtualFile
54

65
class TaskExecutableFileChooserDescriptor : FileChooserDescriptor(true, false, false, false, false, false) {
76
init {
87
title = "Select Task Executable"
9-
}
10-
11-
override fun isFileSelectable(file: VirtualFile?): Boolean {
12-
if (file == null || file.isDirectory) {
13-
return false
8+
withFileFilter { file ->
9+
val filename = file.name
10+
"task".equals(filename, ignoreCase = true) || "task.exe".equals(filename, ignoreCase = true)
1411
}
15-
val filename = file.name
16-
return "task".equals(filename, ignoreCase = true) || "task.exe".equals(filename, ignoreCase = true)
1712
}
1813
}
Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,13 @@
11
package lechuck.intellij
22

33
import com.intellij.openapi.fileChooser.FileChooserDescriptor
4-
import com.intellij.openapi.vfs.VirtualFile
54

65
class TaskfileFileChooserDescriptor : FileChooserDescriptor(true, false, false, false, false, false) {
76
init {
87
title = "Select Taskfile"
9-
}
10-
11-
override fun isFileSelectable(file: VirtualFile?): Boolean {
12-
if (file == null || file.isDirectory) {
13-
return false
8+
withFileFilter { file ->
9+
val ext = file.extension
10+
"yaml".equals(ext, ignoreCase = true) || "yml".equals(ext, ignoreCase = true)
1411
}
15-
16-
val ext = file.extension
17-
return "yaml".equals(ext, ignoreCase = true) || "yml".equals(ext, ignoreCase = true)
1812
}
1913
}

src/main/resources/META-INF/plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
]]></description>
2828

2929
<change-notes><![CDATA[
30-
v1.7.0
30+
v1.7.1
3131
<ul>
3232
<li>change minimum requirements: 2024.1</li>
3333
<li>fix deprecated API usages</li>

0 commit comments

Comments
 (0)