passing expression instead of hard coded resource.list() call