@@ -409,6 +409,8 @@ function allIncluded(outputTarget = 'email') {
409
409
reviewedPrsArray = [ ] ;
410
410
githubPrsReviewDataProccessed = { } ;
411
411
412
+ writeGithubIssuesPrs ( ) ;
413
+ writeGithubPrsReviews ( ) ;
412
414
// Update subject
413
415
if ( ! githubCache . subject && scrumSubject ) {
414
416
scrumSubjectLoaded ( ) ;
@@ -423,7 +425,7 @@ function allIncluded(outputTarget = 'email') {
423
425
424
426
//load initial text in scrum body
425
427
function writeScrumBody ( ) {
426
- if ( ! enableToggle || hasInjectedContent ) return ;
428
+ if ( ! enableToggle || ( outputTarget === 'email' && hasInjectedContent ) ) return ;
427
429
428
430
if ( outputTarget === 'email' ) {
429
431
if ( ! window . emailClientAdapter ) {
@@ -486,7 +488,6 @@ function allIncluded(outputTarget = 'email') {
486
488
logError ( 'Scrum report div not found' ) ;
487
489
}
488
490
} else {
489
-
490
491
const elements = window . emailClientAdapter . getEditorElements ( ) ;
491
492
if ( ! elements || ! elements . body ) {
492
493
console . error ( 'Email client editor not found' ) ;
@@ -711,15 +712,29 @@ function allIncluded(outputTarget = 'email') {
711
712
712
713
//check for github safe writing
713
714
let intervalWriteGithubIssues = setInterval ( ( ) => {
714
- if ( scrumBody && githubUsername && githubIssuesData ) {
715
- clearInterval ( intervalWriteGithubIssues ) ;
716
- writeGithubIssuesPrs ( ) ;
715
+ if ( outputTarget === 'popup' ) {
716
+ if ( githubUsername && githubIssuesData ) {
717
+ clearInterval ( intervalWriteGithubIssues ) ;
718
+ writeGithubIssuesPrs ( ) ;
719
+ }
720
+ } else {
721
+ if ( scrumBody && githubUsername && githubIssuesData ) {
722
+ clearInterval ( intervalWriteGithubIssues ) ;
723
+ writeGithubIssuesPrs ( ) ;
724
+ }
717
725
}
718
726
} , 500 ) ;
719
727
let intervalWriteGithubPrs = setInterval ( ( ) => {
720
- if ( scrumBody && githubUsername && githubPrsReviewData ) {
721
- clearInterval ( intervalWriteGithubPrs ) ;
722
- writeGithubPrsReviews ( ) ;
728
+ if ( outputTarget === 'popup' ) {
729
+ if ( githubUsername && githubPrsReviewData ) {
730
+ clearInterval ( intervalWriteGithubPrs ) ;
731
+ writeGithubPrsReviews ( ) ;
732
+ }
733
+ } else {
734
+ if ( scrumBody && githubUsername && githubPrsReviewData ) {
735
+ clearInterval ( intervalWriteGithubPrs ) ;
736
+ writeGithubPrsReviews ( ) ;
737
+ }
723
738
}
724
739
} , 500 ) ;
725
740
if ( ! refreshButton_Placed ) {
0 commit comments