Will Smith is very smart, and this movie was made for a fairly small budget compared to other Will Smith movies. It cost $50 million to make and has already made its money back ($80 million worldwide so far).
Stats here. It will easily pass the $100 million worldwide, but probably harder to do that domestically (USA). It won't be Wills biggest film, but like After Earth even if a Will Smith film is average he's smart enough to market it the right way and make sure the film makes its money back plus a profit. Will produces a lot of his films now so if it loses money he takes the hit but when it does well he reaps the rewards.
Its very encouraging to see a young hot blonde like Margot Robbie, who just came off a great performance alongside Leonard DiCaprio, transition into this type of pairing and for it not to effect her career. So often we hear garbage about an interracial pairing ruining the career of the BM or WW. This proves it doesn't. Will and Margot are still in demand and will go on to make more movies.
I'd love to see Denzel get a decent young love interest, I don't see why his hardcore fans would be upset - it is only acting after all.