Hi Atul,
As you suggested the bug is easily fixed by going this way : https://github.com/phpmyadmin/phpmyadmin/commit/49d60e0dd5b2d4095f0b83719d45c5e0f1c9043c

I'm not able to understand your alternate solution though.

Thanks
Umair Khan