fixed another typo
modified to accept URLs