Fixed bugs with grappelli >= 2.4