made video a local variable