fixed a bug when resolution is null