public function checkPermission($model, $member = null, $httpMethod)
    {
        if (is_string($model)) {
            $model = singleton($model);
        }

        // check permission depending on HTTP verb
        // default to true
        switch (strtoupper($httpMethod)) {
            case 'GET':
                return $model->canView($member);
                break;

            case 'POST':
                return $model->canCreate($member);
                break;

            case 'PUT':
                return $model->canEdit($member);
                break;

            case 'DELETE':
                return $model->canDelete($member);
                break;

            default:
                return true;
                break;
        }
    }