better common.ml, avoid copy paste of globals, dangerous