sync with latest working example