Web Symbols: remove unnecessary TODO comment

GitOrigin-RevId: 17dad2b6d46c82d2e019ba2c54fd6e1891cd3dc8
This commit is contained in:
Piotr Tomiak
2022-11-23 09:33:12 +01:00
committed by intellij-monorepo-bot
parent 214599080e
commit 267f186017

View File

@@ -14,8 +14,8 @@ import com.intellij.psi.xml.XmlTag
import com.intellij.util.ArrayUtil
import com.intellij.webSymbols.PsiSourcedWebSymbol
import com.intellij.webSymbols.WebSymbol
import com.intellij.webSymbols.completion.WebSymbolCodeCompletionItem
import com.intellij.webSymbols.WebSymbolsBundle
import com.intellij.webSymbols.completion.WebSymbolCodeCompletionItem
import com.intellij.webSymbols.utils.unwrapMatchedSymbols
import com.intellij.xml.impl.BasicXmlAttributeDescriptor
import com.intellij.xml.impl.XmlAttributeDescriptorEx
@@ -49,10 +49,8 @@ open class WebSymbolAttributeDescriptor private constructor(val tag: XmlTag?,
override fun getDefaultValue(): String? = defaultValue
override fun validateValue(context: XmlElement?, value: String?): String? {
// todo validateValue comes from XML plugin, not aware of frameworks,
// so might be a good idea to eagerly discard stringified value here if it comes from an expression
return when {
override fun validateValue(context: XmlElement?, value: String?): String? =
when {
value == null -> null
!acceptsValue -> WebSymbolsBundle.message("web.inspection.message.attribute.does.not.accept.value", name)
supportsEnums && strictEnumValues -> {
@@ -67,7 +65,6 @@ open class WebSymbolAttributeDescriptor private constructor(val tag: XmlTag?,
}
else -> null
}
}
override fun validateAttributeName(attribute: XmlAttribute, holder: ProblemsHolder, isOnTheFly: Boolean) {