Add $this to method variable check in a few functions