TextInputLayout not reverting original edit text background on setError(null)
<p>I am using <strong>TextInputLayout</strong> with <strong>AppCompatEditText</strong> having a custom xml shape based background for <strong>AppCompatEditText</strong>.</p>

<p>My <strong>TextInputLayout</strong> is:</p>

<p><a href="https://i.stack.imgur.com/YRLjj.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YRLjj.png" alt="enter image description here"></a></p>

<p>Where <strong>@drawable/edittext_bg</strong> is :</p>

<p><a href="https://i.stack.imgur.com/sYDRs.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/sYDRs.png" alt="enter image description here"></a></p>

<p>When i set some error on <strong>TextInputLayout</strong>, the background turns red which is OK. But on removing error using <strong>setError(null)</strong>, the background turns grey, not the original one. </p>

<p><a href="https://i.stack.imgur.com/5pOnV.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/5pOnV.jpg" alt="enter image description here"></a></p>

<p><a href="https://i.stack.imgur.com/XMo5I.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XMo5I.jpg" alt="enter image description here"></a></p>

<p><a href="https://i.stack.imgur.com/XWECE.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XWECE.jpg" alt="enter image description here"></a></p>