Implementation of download action.