commutative algebra – Generalization of the Atiyah-Macdonald Proposition 5.7

The proposal is

Let $ A $ $ subseteq $ $ B $ to be integral domains, $ B $ integral on $ A $. then $ B $ is a field so $ A $ is a field.

The proof is easy. I want to generalize this proposition. I want to prove that

Let $ A $$ to $ $ B $ to be integral domains, $ B $ integral on $ A $. then $ B $ is a field so $ A $ is a
field.

One side is easy: suppose $ A $ is a field, let $ y in B, y not = 0 $. Since $ B $ is an integral part of $ A $, let $ y ^ {n} + f (a_ {1}) y ^ {n-1} + … + f (a_ {n}) (a_ {i} to A) $ an integral dependence equation for y of the smallest possible degree. then $ a_n not = 0 $, so $ y ^ {- 1} = – f (a_ {n} ^ {- 1}) (y ^ {n-1} + … + f (a_ {n-1})) in B $, Therefore $ B $ is a field.However, I do not know how to prove the other side: if $ B $ is a field, then $ A $ is a field.

Could you tell me how to prove it?