Made this code shorter.