kafka-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shuai Zhang (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (KAFKA-4053) Refactor TopicCommand to remove redundant if/else statements
Date Mon, 22 Aug 2016 01:59:20 GMT

     [ https://issues.apache.org/jira/browse/KAFKA-4053?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Shuai Zhang closed KAFKA-4053.
------------------------------

This issue is solved by pull request: https://github.com/apache/kafka/pull/1751

> Refactor TopicCommand to remove redundant if/else statements
> ------------------------------------------------------------
>
>                 Key: KAFKA-4053
>                 URL: https://issues.apache.org/jira/browse/KAFKA-4053
>             Project: Kafka
>          Issue Type: Improvement
>          Components: admin
>    Affects Versions: 0.10.0.1
>            Reporter: Shuai Zhang
>            Priority: Minor
>             Fix For: 0.10.1.0
>
>
> In TopicCommand, there are a lot of redundant if/else statements, such as
> ```val ifNotExists = if (opts.options.has(opts.ifNotExistsOpt)) true else false```
> We can refactor it as the following statement:
> ```val ifNotExists = opts.options.has(opts.ifNotExistsOpt)```



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message