Made $data protected in BaseController.