update origin directive
more bugs