Fixed "undefined index" error and added composer.json file.