Preparation of MoS2 and WS2 catalysts by in situ decomposition of ammonium thiosalts