Modified author
Modified 1-n to m-n model and error handling