method name offer not declared properly