shorten picture urls in db