added support for demo mode