fixed darkbox bug