Several fixes to shiny