isYesterday method

bool isYesterday()

Implementation

bool isYesterday() {
  return year == DateTime.now().year &&
      month == DateTime.now().month &&
      day == DateTime.now().day - 1;
}