public static function update_competency($competency) {
        $params = self::validate_parameters(self::update_competency_parameters(), array(
            'competency' => $competency
        ));
        $params = $params['competency'];

        $competency = api::read_competency($params['id']);
        self::validate_context($competency->get_context());

        $params = (object) $params;

        return api::update_competency($params);
    }
public static function update_competency($competency) {
        $params = self::validate_parameters(self::update_competency_parameters(), array(
            'competency' => $competency
        ));
        $params = $params['competency'];

        $competency = api::read_competency($params['id']);
        self::validate_context($competency->get_context());

        $params = (object) $params;

        return api::update_competency($params);
    }
public static function update_competency ( $ competency ) { $ params = self :: validate_parameters ( self :: update_competency_parameters ( ) , array ( 'competency' => $ competency ) ) ; $ params = $ params [ 'competency' ] ; $ competency = api :: read_competency ( $ params [ 'id' ] ) ; self :: validate_context ( $ competency -> get_context ( ) ) ; $ params = ( object ) $ params ; return api :: update_competency ( $ params ) ; }
Update an existing competency

@param array $competency The array of competency fields (id is required).
@return boolean
Update an existing competency