Minor: bugfix for the Java requireSingleCommand API.

This commit is contained in:
Mike Hearn 2016-02-03 15:34:37 +01:00
parent 606926a692
commit af116f6990

View File

@ -124,7 +124,7 @@ inline fun <reified T : CommandData> List<AuthenticatedObject<CommandData>>.requ
// For Java
fun List<AuthenticatedObject<CommandData>>.requireSingleCommand(klass: Class<out CommandData>) =
filter { klass.isInstance(it) }.single()
filter { klass.isInstance(it.value) }.single()
/** Returns a timestamp that was signed by the given authority, or returns null if missing. */
fun List<AuthenticatedObject<CommandData>>.getTimestampBy(timestampingAuthority: Party): TimestampCommand? {