added android middleware