Made more logic