@Override
	public void addLocation(String location, String albumName){
		albumName = albumName.toLowerCase();
		location = location.toLowerCase();
		Album album = findById(albumName);
		if(album != null) {
			JpaLocationDao jld = new JpaLocationDao();
			Location loc = jld.findById(location);
			if(loc != null){
				List<AlbumI> albums = (List<AlbumI>) loc.getAlbums();

				if((!albums.contains(album))){

					beginTransaction();
					albums.add(album);
					loc.setAlbums(albums);
					album .setLocation(loc);
					persist(album);
					entityManager.persist(loc);
					commitTransaction();
				}
			}else{
				beginTransaction();
				loc= new Location();
				loc.setLocation(location);
				List<Album> albums = new ArrayList<Album>();
				albums.add(album);
				loc.setAlbums(albums);
				album .setLocation(loc);
				entityManager.persist(loc);
				persist(album);
				commitTransaction();
			}
		}

	}