fix bug when no views
fix bug when no views
fixes for standalon module