fixed some stuff but trying a different approach