Cleaned up working example