adds improvements to constructor naming and behaviour in different environments