flxrandom fixes, please see comment