Added some checks for when no StartPage has been defined yet.
Hide categories
Added check om metadata parameter