Open the app on your smartphone and make sure that it is updated.
Now tap on the 'Account' option from the drop down
Scroll down and tap on the Privacy option
Now click on 'Last seen & online'
Select the "Who can see me online" option
Select the contacts as per your preference.