reordering as suggested by @davr