serious changes, uploaded to sync with local version