Check if `text` is set to avoid IndexError (#4209)
Check if `text` is set to avoid IndexError (#4209)

Fix for https://github.com/huggingface/transformers/issues/3809
huggingface/transformers,huggingface/transformers,huggingface/transformers,huggingface/transformers,huggingface/pytorch-transformers