Moved Application adapter to a separate file