Added error parameter in KwsMedia for PubNub demo

Change-Id: I03d0b6aede7c82b069ea5341ba3e9336ef52097e