replaced demo code with shakehadns code