`decoder_config` variable not defined in EncoderDecoderModel.from_encoder_decoder_pretrained
https://github.com/huggingface/transformers/blob/890e790e16084e58a1ecb9329c98ec3e76c45994/src/transformers/modeling_encoder_decoder.py#L330

Using this function results in an error:

`UnboundLocalError: local variable 'decoder_config' referenced before assignment`

Suggest changing `decoder_config.add_cross_attention` to `kwargs_decoder["config"].add_cross_attention`


@jsilter - great catch! I agree 100% with your suggestion! Do you want to open a PR to fix it? :-) <|||||>https://github.com/huggingface/transformers/pull/7903 this is already fixed yesterday @jsilter 