fixed error with join