Bug fixed with views, tested and working