improved some utilities