fixes #233: only set tile source if valid