Moved the drop function into a separate file