@Override
	public ArrayList<Task> loadTasks() {
		LocalDateTime now = DateTime.now().toLocalDateTime();

		if (isStorageExists()) {
			try {
				YamlReader rd = new YamlReader(new FileReader(storagePath));
				Task t;
				while ((t = (Task) rd.read())!=null) {
					storage.add(t);
				}
			} catch (IOException e) {
				logger.log(Level.WARNING,"EXCEPTION OCCURED WHEN LOADING TASK");
				e.printStackTrace();
			}
		}

		for(int i = 0; i < storage.size(); i++){//on startup, check expired tasks
			Task temp = storage.get(i);
			LocalDateTime tempEnd = temp.parseStringToDate(temp.endTime);
			if(tempEnd.isBefore(now)){
				temp.setTaskStatus(STATUS_UNFINISHED);
			} else if((temp.getTaskStatus().equalsIgnoreCase(STATUS_UNFINISHED) && tempEnd.isAfter(now))){
				temp.setTaskStatus(STATUS_PENDING);
			}
		}
		logger.log(Level.INFO,"Tasks loaded.");
		return storage;
	}