code: def self_if_parameters(func):
      
      @wraps(func)
      def wrapper(self, *args, **kwargs):
          result = func(self, *args, **kwargs)
          if args or kwargs:
              return self
          else:
              return result
      return wrapper
docs: If any parameter is given, the method's binded object is returned after
      executing the function. Else the function's result is returned.