minor changes -> slightly more abstracted