Fixed bug in MainActivity.