Fixed minor bugs:
Fixed query for choosing last gallery with pic;
Fixed static events.json generation;
Fixed pagination.json generation for new/promo/events;