try to rewrite the whole thing, no big difference