Fixed error and created all required methods