Fixed a few bugs, added SecurityError warning.