Do we need {} in if? When it is only one operator,...
# announcements
h
Do we need {} in if? When it is only one operator, should I add {} after if? Here is a sample: if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) { window.statusBarColor = Util.getColor(R.color.accent_color) }
a
With regards to braces for `if`s I follow this rule https://android.github.io/kotlin-guides/style.html#braces