Formation and electrocatalysis studies of nickel and iron sulfide catalysts using in situ XAS