Probably should be 
```python
if instance and arrPassword[i]:
```