updated xapp middleware to not depend on sharify