From 78d6ae649fe82257ab104ae93c4876031dd8e241 Mon Sep 17 00:00:00 2001 From: Arpita Patel Date: Thu, 21 Sep 2023 14:33:55 -0400 Subject: [PATCH] fix url --- .../slack/sgp/intellij/featureflags/FeatureFlagExtractor.kt | 4 ++-- .../slack/sgp/intellij/featureflags/featureFlagAnnotator.kt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/FeatureFlagExtractor.kt b/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/FeatureFlagExtractor.kt index 1d62e5260..826e37b68 100644 --- a/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/FeatureFlagExtractor.kt +++ b/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/FeatureFlagExtractor.kt @@ -84,7 +84,7 @@ class FeatureFlagExtractor { * @param element The enum entry to check. * @return true if the enum entry is a feature flag, false otherwise. */ - fun hasFeatureFlagAnnotation(element: Any): Boolean { + private fun hasFeatureFlagAnnotation(element: Any): Boolean { val annotationEntriesMethod = element.javaClass.getMethod("getAnnotationEntries") val annotationEntries = annotationEntriesMethod.invoke(element) as? List<*> return annotationEntries?.any { @@ -95,7 +95,7 @@ class FeatureFlagExtractor { ?: false } - fun isKtEnumEntry(element: Any): Boolean { + private fun isKtEnumEntry(element: Any): Boolean { LOG.info("Checking if element is KtEnumEntry") val result = element.javaClass.name == "org.jetbrains.kotlin.psi.KtEnumEntry" LOG.info("Element isKtEnumEntry: $result") diff --git a/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/featureFlagAnnotator.kt b/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/featureFlagAnnotator.kt index db418d5a7..1763805bc 100644 --- a/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/featureFlagAnnotator.kt +++ b/skate-plugin/src/main/kotlin/com/slack/sgp/intellij/featureflags/featureFlagAnnotator.kt @@ -91,7 +91,7 @@ class FeatureFlagAnnotator : ExternalAnnotator> findTextRangeForFlag(psiFile, flag) } if (textRange != null) { - val url = "$baseUrl?q=$flag" + val url = "$baseUrl?q=${flag.lowercase()}" FeatureFlagSymbol(textRange, url) } else { null