I did it because on_load is a name for an anonymous function but probably we don't need that if we go for the code suggested by you below