Refactor... or something