Skip to content
This repository was archived by the owner on Aug 18, 2020. It is now read-only.

Commit 37994db

Browse files
committed
Further improved documentation
1 parent 9d1771c commit 37994db

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,4 @@ project/plugins/project/
3333
/bin/
3434
/lib/
3535
/deploy/
36+
/wiki/

src/main/scala/org/codeoverflow/chatoverflow/requirement/service/sample/SampleConnector.scala

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,14 @@ import org.codeoverflow.chatoverflow.connector.Connector
55

66
class SampleConnector(override val sourceIdentifier: String) extends Connector(sourceIdentifier) with WithLogger {
77
override protected var requiredCredentialKeys: List[String] = List()
8-
override protected var optionalCredentialKeys: List[String] = List()
8+
override protected var optionalCredentialKeys: List[String] = List("optionalSample")
99

1010
/**
1111
* Starts the connector, e.g. creates a connection with its platform.
1212
*/
1313
override def start(): Boolean = {
14+
val optionalSample: Option[String] = credentials.get.getValue("optionalSample")
15+
if (optionalSample.isEmpty) logger info "Credentials value optionalSample was not set"
1416
logger info s"Started sample connector! Source identifier is: '$sourceIdentifier'."
1517
true
1618
}

0 commit comments

Comments
 (0)