mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-08-04 13:43:23 +00:00
refactor(github) auth
This commit is contained in:
parent
6d84f734d2
commit
8ac1cc5837
4 changed files with 36 additions and 29 deletions
|
|
@ -6,14 +6,9 @@
|
|||
(function(){
|
||||
'use strict';
|
||||
|
||||
var GitHub,
|
||||
opener = window.opener;
|
||||
|
||||
if (opener) {
|
||||
GitHub = opener.CloudCmd.GitHub;
|
||||
GitHub.autorize(GitHub.callback, window.location.search);
|
||||
window.close();
|
||||
}
|
||||
window.addEventListener('message', function(event) {
|
||||
event.source.postMessage(window.location.search, event.origin);
|
||||
});
|
||||
})();
|
||||
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue