it works but it has many bugs