Make use of OpResult
Fix samples