This code could be extracted into an external module, to keep this yz_app code cleaner