added delete feature to tweets API and refactored some lines of update