Try to reduce method complexity.