Skip to content

Commit 206b55f

Browse files
committed
Fixed code
1 parent b0c9b18 commit 206b55f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

library/src/main/java/co/kyash/vtl/ValidatableTextInputLayout.kt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,14 @@ class ValidatableTextInputLayout @JvmOverloads constructor(
5151
a.recycle()
5252
}
5353

54+
val textInputAwareValidationFlowables: ArrayList<Flowable<Any>> = ArrayList()
55+
5456
private val textProcessor: FlowableProcessor<String> = PublishProcessor.create()
5557

5658
private val compositeDisposable: CompositeDisposable = CompositeDisposable()
5759

5860
private val validators: ArrayList<VtlValidator> = ArrayList()
5961

60-
private val textInputAwareValidationFlowables: ArrayList<Flowable<Any>> = ArrayList()
61-
6262
private val mainHandler: Handler = HandlerProvider.createMainHandler()
6363

6464
private val textWatcher = object : TextWatcher {
@@ -111,7 +111,6 @@ class ValidatableTextInputLayout @JvmOverloads constructor(
111111
private fun initListeners() {
112112
val editText = editText ?: return
113113

114-
// If the text has error, validation should run on realtime.
115114
if (shouldValidateOnTextChanged || shouldValidateOnTextChangedOnce) {
116115
shouldValidateOnTextChangedOnce = TextUtils.isEmpty(error)
117116
editText.removeTextChangedListener(textWatcher)

0 commit comments

Comments
 (0)