This quote means that if you are able to stay positive and use humor when times are tough, then it can make your hardships easier to deal with. It is much easier to be humorous when everything is going well and life is good, but it takes more effort to keep up your sense of humor when facing difficulties. Having a sense of humor can help lighten the load in tough times.