Fixed bug for iPAD