Skip to content

Commit

Permalink
Remove detekt
Browse files Browse the repository at this point in the history
  • Loading branch information
deen13 committed Mar 10, 2021
1 parent c1971ee commit b567137
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
1 change: 0 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ plugins {
id 'maven-publish'
id "org.jetbrains.kotlin.jvm" version "$kotlinVersion"
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
id 'io.gitlab.arturbosch.detekt' version "1.15.0"
}

repositories {
Expand Down
3 changes: 2 additions & 1 deletion src/main/kotlin/de/smartsquare/starter/mqtt/Adapter.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import com.hivemq.client.mqtt.mqtt3.message.publish.Mqtt3Publish
import org.slf4j.LoggerFactory
import org.springframework.beans.factory.InitializingBean
import org.springframework.stereotype.Component
import java.lang.reflect.InvocationTargetException
import java.lang.reflect.Method

@Component
Expand Down Expand Up @@ -46,7 +47,7 @@ class Adapter(
val parameters = subscriber.parameterTypes.map { resolve(it, msg, payloadType) }.toTypedArray()

subscriber.invoke(bean, *parameters)
} catch (e: Exception) {
} catch (e: InvocationTargetException) {
logger.error("Error while delivering the message.", e)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@ package de.smartsquare.starter.mqtt
import com.hivemq.client.mqtt.mqtt3.message.connect.connack.Mqtt3ConnAck

class BrokerConnectException(message: String) : RuntimeException(message) {
constructor(acknowledgement: Mqtt3ConnAck) : this("Unable to connect to broker. Return Code: ${acknowledgement.returnCode.code}")
constructor(acknowledgement: Mqtt3ConnAck) : this(
"Unable to connect to broker. Return Code: ${acknowledgement.returnCode.code}"
)
}

0 comments on commit b567137

Please sign in to comment.