IDEA-CR-28745 check that storages list not empty

This commit is contained in:
Vladimir Krivosheev
2018-01-24 19:51:54 +01:00
parent 7eb824bfef
commit de7ff37a61
@@ -12,7 +12,7 @@ internal fun createComponentInfo(component: Any, stateSpec: State?): ComponentIn
else -> ComponentInfoImpl(component, stateSpec)
}
if (stateSpec != null && stateSpec.storages.all { it.roamingType === RoamingType.DISABLED }) {
if (stateSpec != null && !stateSpec.storages.isEmpty() && stateSpec.storages.all { it.roamingType === RoamingType.DISABLED }) {
componentInfo.lastSaved = (System.currentTimeMillis() / 1000).toInt()
}