What if the battery goes dead before the drone lands?

There are safeguards put into play for this scenario.  The drone is connected to an iPad with software that is tracking the battery life.  Once it gets to a certain level it will give a warning.  If it gets too low, the drone automatically returns to home base.